Skip to content

Commit

Permalink
Support shoulder.fan (fixes #1350)
Browse files Browse the repository at this point in the history
  • Loading branch information
qsniyg committed Aug 18, 2024
1 parent 6ed5575 commit 208c134
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/userscript.ts
Original file line number Diff line number Diff line change
Expand Up @@ -115530,6 +115530,13 @@ var $$IMU_EXPORT$$;
return src.replace(/(\/upload\/+[0-9A-F]+\/+[0-9]{6}\/+[^/?#]+\.[a-z]+)_[0-9]+x[0-9]+\.ashx(?:[?#].*)?$/, "$1");
}

if (domain_nosub === "berapt.com" && /^cdn[0-9]*\./.test(domain)) {
// thanks to Froktime on github: https://github.com/qsniyg/maxurl/issues/1350
if (/\/i\/+[^/]+\/+[0-9a-f/]+\//.test(src)) {
return add_queries(keep_queries(src, ["h", "p", "s"]), {"size": "origin"});
}
}




Expand Down
6 changes: 6 additions & 0 deletions userscript.user.js
Original file line number Diff line number Diff line change
Expand Up @@ -103735,6 +103735,12 @@ var $$IMU_EXPORT$$;
// https://file01.es.c01.co/upload/E9E55B4EDD33C8E0/202402/4768047368473278140.jpg -- 3750x5000
return src.replace(/(\/upload\/+[0-9A-F]+\/+[0-9]{6}\/+[^/?#]+\.[a-z]+)_[0-9]+x[0-9]+\.ashx(?:[?#].*)?$/, "$1");
}
if (domain_nosub === "berapt.com" && /^cdn[0-9]*\./.test(domain)) {
// thanks to Froktime on github: https://github.com/qsniyg/maxurl/issues/1350
if (/\/i\/+[^/]+\/+[0-9a-f/]+\//.test(src)) {
return add_queries(keep_queries(src, ["h", "p", "s"]), { "size": "origin" });
}
}
// -- general rules --
if (src.match(/\/ImageGen\.ashx\?/)) {
// http://www.lookalikes.info/umbraco/ImageGen.ashx?image=/media/97522/nick%20hewer%20-%20mark%20brown.jpeg&width=250&constrain=true
Expand Down

0 comments on commit 208c134

Please sign in to comment.