mirror of
https://github.com/langbot-app/LangBot.git
synced 2026-06-02 03:55:55 +00:00
fix(plugin): resolve plugin page asset origin
This commit is contained in:
@@ -590,6 +590,9 @@ export class BackendClient extends BaseHttpClient {
|
||||
name: string,
|
||||
filepath: string,
|
||||
): string {
|
||||
if (this.instance.defaults.baseURL === '/') {
|
||||
return `${window.location.origin}/api/v1/plugins/${author}/${name}/assets/${filepath}`;
|
||||
}
|
||||
return (
|
||||
this.instance.defaults.baseURL +
|
||||
`/api/v1/plugins/${author}/${name}/assets/${filepath}`
|
||||
|
||||
Reference in New Issue
Block a user