mirror of
https://codeberg.org/LibRedirect/libredirect.git
synced 2025-02-08 16:18:41 +01:00
Fixed bug. 2.8.3 => 2.8.4
This commit is contained in:
parent
fee58c5650
commit
1b529ed392
@ -62,13 +62,12 @@ async function redirectAsync(url, type, initiator, forceRedirection) {
|
||||
}
|
||||
|
||||
/**
|
||||
* @param url
|
||||
* @param frontend
|
||||
* @param randomInstance
|
||||
* @param {URL} url
|
||||
* @param {string} frontend
|
||||
* @param {string} randomInstance
|
||||
* @returns {undefined|string}
|
||||
*/
|
||||
function rewrite(url, frontend, randomInstance) {
|
||||
if (!frontend || !randomInstance) return
|
||||
switch (frontend) {
|
||||
case "hyperpipe": {
|
||||
return `${randomInstance}${url.pathname}${url.search}`.replace(/\/search\?q=.*/, searchQuery => searchQuery.replace("?q=", "/"))
|
||||
@ -316,7 +315,6 @@ function rewrite(url, frontend, randomInstance) {
|
||||
if (notExchangeRegex) {
|
||||
return `${randomInstance}/exchange/${notExchangeRegex[0]}${url.pathname}${url.search}`
|
||||
}
|
||||
// "Default case"
|
||||
return `${randomInstance}${url.pathname}${url.search}`
|
||||
}
|
||||
case "biblioReads": {
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "__MSG_extensionName__",
|
||||
"description": "__MSG_extensionDescription__",
|
||||
"version": "2.8.3",
|
||||
"version": "2.8.4",
|
||||
"manifest_version": 2,
|
||||
"browser_specific_settings": {
|
||||
"gecko": {
|
||||
|
@ -1,6 +1,6 @@
|
||||
<?xml version='1.0' encoding='UTF-8'?>
|
||||
<gupdate xmlns='http://www.google.com/update2/response' protocol='2.0'>
|
||||
<app appid='oladmjdebphlnjjcnomfhhbfdldiimaf'>
|
||||
<updatecheck codebase='https://github.com/libredirect/libredirect/releases/download/v2.8.3/libredirect-2.8.3.crx' version='2.8.3' />
|
||||
<updatecheck codebase='https://github.com/libredirect/libredirect/releases/download/v2.8.4/libredirect-2.8.4.crx' version='2.8.4' />
|
||||
</app>
|
||||
</gupdate>
|
||||
|
Loading…
x
Reference in New Issue
Block a user