diff --git a/ui/src/plugins/advent22.ts b/ui/src/plugins/advent22.ts index 42f3568..535bde1 100644 --- a/ui/src/plugins/advent22.ts +++ b/ui/src/plugins/advent22.ts @@ -25,7 +25,7 @@ export class Advent22 { public api_url(endpoint?: string): string { if (endpoint === undefined) - return `${this.api_baseurl}`; + return this.api_baseurl; return `${this.api_baseurl}/${endpoint}`; } @@ -66,6 +66,9 @@ export class Advent22 { reader.onloadend = () => { if (typeof reader.result === "string") on_success(reader.result); + + else + this.fail(endpoint); } }, "blob",