cleanup + fix feed
This commit is contained in:
parent
244f7e40ce
commit
a13c7cbc22
5 changed files with 18 additions and 14 deletions
|
|
@ -48,8 +48,7 @@ export class Backend {
|
|||
}
|
||||
|
||||
async fetch(url: string, options?: RequestInit) {
|
||||
console.info(`fetch ${Backend.ENDPOINT_BASE}/${encodeURIComponent(url)}`)
|
||||
return await fetch(`${Backend.ENDPOINT_BASE}/${encodeURIComponent(url)}`, options);
|
||||
return await fetch(`${Backend.ENDPOINT_BASE}/${url.replace(/^\/+/, '')}`, options);
|
||||
}
|
||||
|
||||
withEvent(event: any) {
|
||||
|
|
@ -76,6 +75,7 @@ class EventBackend extends Backend {
|
|||
}
|
||||
|
||||
async fetch(url: string, options?: RequestInit): Promise<Response> {
|
||||
console.debug(`fetch ${Backend.ENDPOINT_BASE}/${url.replace(/^\/+/, '')}`);
|
||||
return await this.event.fetch(`${Backend.ENDPOINT_BASE}/${url.replace(/^\/+/, '')}`, options);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue