From 4650b8778ad2bb0ea946a6d65ea8611bdceeae8b Mon Sep 17 00:00:00 2001 From: gorhill Date: Sat, 12 Mar 2016 10:48:31 -0500 Subject: [PATCH] this fixes #1471 --- src/js/tab.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/js/tab.js b/src/js/tab.js index b7b92897e..41cb37724 100644 --- a/src/js/tab.js +++ b/src/js/tab.js @@ -647,7 +647,10 @@ vAPI.tabs.onPopupUpdated = (function() { if ( pos === -1 ) { return ''; } - if ( beg >= pos + openerHostname.length || end < pos ) { + // https://github.com/gorhill/uBlock/issues/1471 + // We test whether the opener hostname as at least one character + // within matched portion of URL. + if ( beg >= pos + openerHostname.length || end <= pos ) { return ''; } return result;