Bladeren bron

Merge pull request #586 from jitsi/inline_not_supported

feat(SS): handle inline installation not supported error.
master
Saúl Ibarra Corretgé 7 jaren geleden
bovenliggende
commit
dd163e95f9
1 gewijzigde bestanden met toevoegingen van 12 en 1 verwijderingen
  1. 12
    1
      modules/RTC/ScreenObtainer.js

+ 12
- 1
modules/RTC/ScreenObtainer.js Bestand weergeven

@@ -59,6 +59,16 @@ const CHROME_EXTENSION_INLINE_ERROR
59 59
     = 'Installs can only be initiated by one of'
60 60
         + ' the Chrome Web Store item\'s verified sites.';
61 61
 
62
+/**
63
+ * The error returned by chrome when trying to start inline installation
64
+ * with extension that doesn't support inline installation.
65
+ *
66
+ * @type {string}
67
+ */
68
+const CHROME_EXTENSION_INLINE_NOT_SUPPORTED_ERROR
69
+    = 'Inline installation is not supported for this item. '
70
+        + 'The user will be redirected to the Chrome Web Store.';
71
+
62 72
 /**
63 73
  * The error message returned by chrome when the extension is installed.
64 74
  */
@@ -417,7 +427,8 @@ const ScreenObtainer = {
417 427
 
418 428
         if ((CHROME_EXTENSION_POPUP_ERROR === e
419 429
              || CHROME_EXTENSION_IFRAME_ERROR === e
420
-             || CHROME_EXTENSION_INLINE_ERROR === e)
430
+             || CHROME_EXTENSION_INLINE_ERROR === e
431
+             || CHROME_EXTENSION_INLINE_NOT_SUPPORTED_ERROR === e)
421 432
                 && options.interval > 0
422 433
                 && typeof options.checkAgain === 'function'
423 434
                 && typeof options.listener === 'function') {

Laden…
Annuleren
Opslaan