fix(audio): clear input device IDs if getUserMedia fails
Stored input device IDs are not cleaned up whenever getUserMedia fails with `NotFoundError` (i.e.: device not found). This causes a couple of issues whenever skipEchoIfPreviousDevice is enabled: - An unnecessary error screen if the user retries audio from scratch (it should just go straight to the audio settings modal) - A retry loop if no other devices are present in the system Guarantee that stored input device IDs are cleared up whenever getUserMedia fails with error name `NotFoundError`. This both the retry loop and the unnecessary error screen.
This commit is contained in:
parent
d0ad8afe64
commit
c2161b9a14
@ -432,6 +432,8 @@ class AudioManager {
|
||||
break;
|
||||
case 'NotFoundError':
|
||||
errorPayload.errCode = AudioErrors.MIC_ERROR.DEVICE_NOT_FOUND;
|
||||
// Reset the input device ID so the user can select a new one
|
||||
this.changeInputDevice(null);
|
||||
logger.error({
|
||||
logCode: 'audiomanager_error_device_not_found',
|
||||
extraInfo: {
|
||||
|
Loading…
Reference in New Issue
Block a user