Merge pull request #688 from Flamenco/patch-2
Check for outboundStreamOpts before accessing it
This commit is contained in:
commit
6d37e4ce1f
@ -536,12 +536,15 @@ export class Stream {
|
||||
* @hidden
|
||||
*/
|
||||
isSendScreen(): boolean {
|
||||
if (!this.outboundStreamOpts) {
|
||||
return false;
|
||||
}
|
||||
let screen = this.outboundStreamOpts.publisherProperties.videoSource === 'screen';
|
||||
if (platform.isElectron()) {
|
||||
screen = typeof this.outboundStreamOpts.publisherProperties.videoSource === 'string' &&
|
||||
this.outboundStreamOpts.publisherProperties.videoSource.startsWith('screen:');
|
||||
}
|
||||
return !!this.outboundStreamOpts && screen;
|
||||
return screen;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user