mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
ui: enable service worker on assets host
This commit is contained in:
2 files changed
+3
-1
No files matched your search
@@ -180,7 +180,8 @@ async function get(request: Request) {
|
||||
|
||||
function transformUrl(url: string) {
|
||||
const urlObject = new URL(url);
|
||||
if (urlObject.pathname.startsWith('/fs/')) urlObject.search = '';
|
||||
const path = urlObject.pathname;
|
||||
if (path.startsWith('/fs/') || path.includes('X-Amz')) urlObject.search = '';
|
||||
return urlObject.toString();
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user