Skip to content

Commit 6c44240

Browse files
Chi-Irohsilverwind
andauthored
Replace location by window.location + removed useless .toString()
Co-authored-by: silverwind <[email protected]>
1 parent 5f324be commit 6c44240

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

web_src/js/features/repo-commit.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ export function initCommitFileHistoryFollowRename() {
3535
checkbox.checked = url.searchParams.has('history_follow_rename', 'true');
3636

3737
checkbox.addEventListener('change', () => {
38-
const url = new URL(location.toString());
38+
const url = new URL(window.location);
3939

4040
url.searchParams.set('history_follow_rename', `${checkbox.checked}`);
4141
window.location.replace(url);

0 commit comments

Comments
 (0)