Skip to content

Commit

Permalink
chore: no longer track.close() when enableLocalAudio(false)
Browse files Browse the repository at this point in the history
  • Loading branch information
guoxianzhe committed Nov 22, 2024
1 parent 582d644 commit 23dce9a
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
5 changes: 0 additions & 5 deletions packages/rtc/src/impl/IAgoraRtcEngineImpl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -560,11 +560,6 @@ export class IRtcEngineImpl implements IRtcEngineExtensions {
} catch (e) {
AgoraConsole.warn(`createAudioTrack error: ${e}`);
}
} else {
await this._engine.irisClientManager.irisClientObserver.notifyLocal(
NotifyType.REMOVE_TRACK,
this._engine.irisClientManager.localAudioTrackPackages
);
}

for (let trackPackage of this._engine.irisClientManager
Expand Down
2 changes: 1 addition & 1 deletion packages/rtc/test/impl/IAgoraRtcEngineImpl.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -799,7 +799,7 @@ describe('IAgoraRtcEngineImpl', () => {
irisRtcEngine.irisClientManager.getLocalAudioTrackPackageBySourceType(
IrisAudioSourceType.kAudioSourceTypeMicrophonePrimary
).length
).toBe(0);
).toBe(1);
await joinChannel(apiEnginePtr, null);
await callIris(apiEnginePtr, 'RtcEngine_enableAudio', null);
expect(
Expand Down

0 comments on commit 23dce9a

Please sign in to comment.