diff --git a/extensions/chromium/runet-censorship-bypass/src/extension-full/80-error-menu.js b/extensions/chromium/runet-censorship-bypass/src/extension-full/80-error-menu.js index fc17832..715a952 100644 --- a/extensions/chromium/runet-censorship-bypass/src/extension-full/80-error-menu.js +++ b/extensions/chromium/runet-censorship-bypass/src/extension-full/80-error-menu.js @@ -18,6 +18,7 @@ return; } let fromPageHref = ''; + let toUrlHref = ''; let fromPageHtml = ''; let youMayReportHtml = ''; const initiator = details.initiator !== 'null' && details.initiator; @@ -26,12 +27,13 @@ fromPageHref = new URL(initiator).href; // Sanitize: only urls, not other stuff. fromPageHtml = ` со страницы ${urlToA(fromPageHref)}`; } + toUrlHref = new URL(details.url).href; youMayReportHtml = ` Вы можете ${'сообщить об ошибке'.link( encodeURIComponent( '/pages/report-proxy-error/index.html?' + new URLSearchParams({ fromPageHref, - requestFailedTo: new URL(details.url).href, + requestFailedTo: toUrlHref, }), ), )} администратору прокси.`; @@ -51,7 +53,7 @@ const popup = `${popupPrefix}${urlToA(details.url)}${fromPageHtml}. Это могло быть намеренно или по ошибке.${youMayReportHtml}#tab=exceptions`; if (tabId < 0) { - throw new Error(`Вы выйграли экзотичную ошибку! Пожалуйста, сообщите нам о ней вместе с адресами ${details.url} и ${fromPageHref}.`); + throw new Error(`Вы выйграли экзотичную ошибку! Пожалуйста, сообщите нам о ней вместе с адресами ${toUrlHref} и ${fromPageHref}.`); } chrome.browserAction.setPopup({ tabId,