Skip to content

Commit 298ccb8

Browse files
committed
i
1 parent 106765f commit 298ccb8

7 files changed

Lines changed: 6 additions & 7 deletions

File tree

dist/404.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
const restPath = l.pathname.slice(1).split('/').slice(pathSegmentsToKeep).join('/');
3434
const newPath = basePath + (basePath.endsWith('/') ? '' : '/') + '?/' + restPath.replace(/&/g, '~and~');
3535
const newSearch = l.search ? '&' + l.search.slice(1).replace(/&/g, '~and~') : '';
36-
window.location.replace(l.protocol + '//' + l.hostname + (l.port ? ':' + l.port : '') + newPath + newSearch + l.hash);
36+
window.location.replace(l.origin + newPath + newSearch + l.hash);
3737
}
3838
})();
3939
</script></head><body></body></html>

dist/bundle-22c92.js

Lines changed: 2 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/bundle-ec0ba.js

Lines changed: 0 additions & 2 deletions
This file was deleted.

dist/index.html

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

src/404.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
const restPath = l.pathname.slice(1).split('/').slice(pathSegmentsToKeep).join('/');
3434
const newPath = basePath + (basePath.endsWith('/') ? '' : '/') + '?/' + restPath.replace(/&/g, '~and~');
3535
const newSearch = l.search ? '&' + l.search.slice(1).replace(/&/g, '~and~') : '';
36-
window.location.replace(l.protocol + '//' + l.hostname + (l.port ? ':' + l.port : '') + newPath + newSearch + l.hash);
36+
window.location.replace(l.origin + newPath + newSearch + l.hash);
3737
}
3838
})();
3939
</script></head><body></body></html>

src/js/github-pages.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,5 @@
1313
// Updated to modern syntax in 2024 for https://github.com/i1li/i
1414
if (window.location.search.startsWith('?/')) {
1515
const decoded = window.location.search.slice(1).split('&').map(s => s.replace(/~and~/g, '&')).join('?');
16-
window.history.replaceState(null, null, window.location.origin + '/' + decoded + window.location.hash);
16+
window.history.replaceState(null, null, window.location.origin + decoded + window.location.hash);
1717
}
18-

0 commit comments

Comments
 (0)