瀏覽代碼

fix(old-safari): check RTCRtpTransceiver exists before checking prototype

master
Leonard Kim 6 年之前
父節點
當前提交
73c4b7ecb1
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1
    1
      modules/browser/BrowserCapabilities.js

+ 1
- 1
modules/browser/BrowserCapabilities.js 查看文件

@@ -255,7 +255,7 @@ export default class BrowserCapabilities extends BrowserDetection {
255 255
             return true;
256 256
         }
257 257
 
258
-        if (this.isSafariWithVP8()) {
258
+        if (this.isSafariWithVP8() && typeof window.RTCRtpTransceiver !== 'undefined') {
259 259
             // eslint-disable-next-line max-len
260 260
             // https://trac.webkit.org/changeset/236144/webkit/trunk/LayoutTests/webrtc/video-addLegacyTransceiver.html
261 261
             // eslint-disable-next-line no-undef

Loading…
取消
儲存