Update src/browser/ScreenDprMonitor.ts

Co-authored-by: Daniel Imms <tyriar@tyriar.com>
This commit is contained in:
Eugene
2020-05-02 22:48:30 +02:00
committed by GitHub
co-authored by Daniel Imms
parent 40a09d7412
commit 930de9aeb7
+1 -3
View File
@@ -49,9 +49,7 @@ export class ScreenDprMonitor extends Disposable {
}
// Clear listeners for old DPR
if (this._resolutionMediaMatchList) {
this._resolutionMediaMatchList.removeListener(this._outerListener);
}
this._resolutionMediaMatchList?.removeListener(this._outerListener);
// Add listeners for new DPR
this._currentDevicePixelRatio = window.devicePixelRatio;