use "default" instead of ""

Signed-off-by: Timo K <toger5@hotmail.de>
This commit is contained in:
Timo K
2025-07-03 13:52:34 +02:00
parent 59cc47bfdb
commit c9915d2252
3 changed files with 4 additions and 4 deletions

View File

@@ -117,7 +117,7 @@ export function useLivekit(
// deviceId here, because it will be set by the native app.
// (also the id does not need to match a browser device id)
deviceId: controlledAudioDevices
? ""
? "default"
: getValue(devices.audioOutput.selected$)?.id,
},
e2ee,
@@ -331,7 +331,7 @@ export function useLivekit(
selected$.subscribe((device) => {
let d = device;
if (controlledAudioDevices && kind === "audiooutput") {
d = { id: "" };
d = { id: "default" };
}
logger.warn(
"[LivekitRoom] syncDevice room.getActiveDevice(kind) !== d.id :",

View File

@@ -1276,7 +1276,7 @@ export class CallViewModel extends ViewModel {
(available, selected) => {
const selectionType = selected && available.get(selected.id)?.type;
// If we are in any output mode other than spaeker switch to speaker.
// If we are in any output mode other than speaker switch to speaker.
const newSelectionType =
selectionType === "speaker" ? "earpiece" : "speaker";
const newSelection = [...available].find(

View File

@@ -306,7 +306,7 @@ class ControlledAudioOutput
(available, preferredId) => {
const id = preferredId ?? available.keys().next().value;
return id === undefined
? undefined
? { id: "default", virtualEarpiece: false }
: { id, virtualEarpiece: id === EARPIECE_CONFIG_ID };
},
).pipe(this.scope.state());