Skip to content

Commit 9f543a1

Browse files
authored
fix: prevent checking isDesktopCapturerEnabled, which crashes on electron@26 (#154)
* Avoid crash with electron 26 Not sure of the side effects of this * Checking isDesktopCapturerEnabled is no longer necessary or possible. Fixes #153 Context electron/electron#38412 * Revert to checking isDesktopCapturerEnabled for pre-26 electron versions
1 parent a6c1cc2 commit 9f543a1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/common/module-names.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ export const browserModuleNames = [
4646

4747
const features = getElectronBinding('features');
4848

49-
if (!features || features.isDesktopCapturerEnabled()) {
49+
if (!features || !features.isDesktopCapturerEnabled || features.isDesktopCapturerEnabled()) {
5050
browserModuleNames.push('desktopCapturer');
5151
}
5252

0 commit comments

Comments
 (0)