mirror of
https://github.com/MercuryWorkshop/scramjet.git
synced 2025-05-13 14:30:02 -04:00
fix: misc bugs
This commit is contained in:
parent
58fed66f78
commit
ca3e09af8e
8 changed files with 20 additions and 28 deletions
|
@ -28,7 +28,7 @@ export function unrewriteBlob(url: string) {
|
|||
|
||||
export function rewriteUrl(url: string | URL, meta: URLMeta) {
|
||||
if (url instanceof URL) {
|
||||
url = url.href;
|
||||
url = url.toString();
|
||||
}
|
||||
|
||||
if (url.startsWith("javascript:")) {
|
||||
|
@ -58,7 +58,7 @@ export function rewriteUrl(url: string | URL, meta: URLMeta) {
|
|||
|
||||
export function unrewriteUrl(url: string | URL) {
|
||||
if (url instanceof URL) {
|
||||
url = url.href;
|
||||
url = url.toString();
|
||||
}
|
||||
|
||||
const prefixed = location.origin + $scramjet.config.prefix;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue