Skip to content

Commit

Permalink
return an empty string if no audiooutput device was set
Browse files Browse the repository at this point in the history
  • Loading branch information
davideberlein committed Nov 1, 2022
1 parent 03ef3e5 commit 0e177e6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/room/Room.ts
Original file line number Diff line number Diff line change
Expand Up @@ -554,10 +554,10 @@ class Room extends (EventEmitter as new () => TypedEmitter<RoomEventCallbacks>)
*
* Note: to get the active `audioinput` or `videoinput` use [[LocalTrack.getDeviceId()]]
*
* @return the previously successfully set audio output device ID or `undefined` in any other case.
* @return the previously successfully set audio output device ID or an empty string if the default device is used.
*/
getActiveAudioOutputDevice(): string | undefined {
return this.options.audioOutput?.deviceId;
getActiveAudioOutputDevice(): string {
return this.options.audioOutput?.deviceId ?? "";
}

/**
Expand Down

0 comments on commit 0e177e6

Please sign in to comment.