diff options
| author | Jason Kim <git@jasonk.me> | 2021-04-09 00:00:42 -0700 | 
|---|---|---|
| committer | Jason Kim <git@jasonk.me> | 2021-04-09 00:00:42 -0700 | 
| commit | e86895b00882d900e9d828a852df54d87211c988 (patch) | |
| tree | eb2cf07d04b3c80e68949a1003c33199fc79cb9d | |
| parent | fix: redirect teddit differently (diff) | |
| download | libredirect-e86895b00882d900e9d828a852df54d87211c988.zip | |
fix: don't redirect for rest of instances
Unbreak old.reddit.com and i.reddit.com by ignoring image redirects for them.
| -rw-r--r-- | src/pages/background/background.js | 2 | 
1 files changed, 2 insertions, 0 deletions
diff --git a/src/pages/background/background.js b/src/pages/background/background.js index bd2d04c4..25342794 100644 --- a/src/pages/background/background.js +++ b/src/pages/background/background.js @@ -454,6 +454,8 @@ function redirectReddit(url, initiator, type) { } else if (redditInstance.includes("teddit")) { let pathWithoutSlash = url.pathname.slice(1); return `${redditInstance}/pics/w:null_${pathWithoutSlash}${url.search}` + } else { + return null; } } return `${redditInstance}${url.pathname}${url.search}`;  | 
