From 16e4473a2c78518e291daac68889dcb0ce9e81bd Mon Sep 17 00:00:00 2001 From: ManeraKai Date: Sat, 22 Jul 2023 13:14:35 +0300 Subject: Hopefully fixing https://github.com/libredirect/browser_extension/issues/765 --- src/assets/javascripts/services.js | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) (limited to 'src/assets') diff --git a/src/assets/javascripts/services.js b/src/assets/javascripts/services.js index d0d85acd..9d66e63d 100644 --- a/src/assets/javascripts/services.js +++ b/src/assets/javascripts/services.js @@ -58,13 +58,6 @@ function redirect(url, type, initiator, forceRedirection) { frontend = options[service].frontend - if ( - config.services[service].embeddable && - type != options[service].redirectType && options[service].redirectType != "both" - ) { - if (options[service].unsupportedUrls == 'block') return 'CANCEL' - return - } if (config.services[service].frontends[frontend].desktopApp && type != "main_frame" && options[service].redirectType != "main_frame") frontend = options[service].embedFrontend @@ -75,6 +68,14 @@ function redirect(url, type, initiator, forceRedirection) { continue } + if ( + config.services[service].embeddable && + type != options[service].redirectType && options[service].redirectType != "both" + ) { + if (options[service].unsupportedUrls == 'block') return 'CANCEL' + return + } + let instanceList = options[frontend] if (instanceList === undefined) break if (instanceList.length === 0) return null -- cgit 1.4.1