ELECTRON-1370 - Add support for RTC v1 api (#730)

This commit is contained in:
Kiran Niranjan 2019-07-15 19:50:50 +05:30 committed by Vishwas Shashidhar
parent 486d345dc4
commit e99b78b061

View File

@ -215,12 +215,14 @@ export class AppBridge {
if (sourceError) {
const { requestId, ...error } = sourceError;
this.broadcastMessage('media-source-callback', { requestId, error });
this.broadcastMessage('media-source-callback-v1', { requestId, error });
return;
}
if (selectedSource && selectedSource.requestId) {
const { requestId, ...source } = selectedSource;
this.broadcastMessage('media-source-callback', { requestId, source, error: sourceError });
this.broadcastMessage('media-source-callback-v1', { requestId, response: { source, error: sourceError } });
}
}