diff options
Diffstat (limited to 'js/location.ts')
-rw-r--r-- | js/location.ts | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/js/location.ts b/js/location.ts index 5d7f44707..535a2bcea 100644 --- a/js/location.ts +++ b/js/location.ts @@ -4,11 +4,6 @@ import { notImplemented } from "./util"; import { Location } from "./dom_types"; import { window } from "./window"; -export function setLocation(url: string): void { - window.location = new LocationImpl(url); - Object.freeze(window.location); -} - export class LocationImpl implements Location { constructor(url: string) { const u = new URL(url); @@ -40,13 +35,18 @@ export class LocationImpl implements Location { port: string; protocol: string; search: string; - assign(url: string): void { + assign(_url: string): void { throw notImplemented(); } reload(): void { throw notImplemented(); } - replace(url: string): void { + replace(_url: string): void { throw notImplemented(); } } + +export function setLocation(url: string): void { + window.location = new LocationImpl(url); + Object.freeze(window.location); +} |