Fix loading from dev server

This commit is contained in:
Yeicor
2025-07-26 17:27:32 +02:00
parent a4acd2f3d3
commit 0be0103c3c

View File

@@ -43,7 +43,7 @@ export class NetworkManager extends EventTarget {
* Updates will be emitted as "update" events, including the download URL and the model name. * Updates will be emitted as "update" events, including the download URL and the model name.
*/ */
async load(url: string | Blob) { async load(url: string | Blob) {
if (url instanceof String && (url.startsWith("dev+") || url.startsWith("dev "))) { if (!(url instanceof Blob) && (url.startsWith("dev+") || url.startsWith("dev "))) {
let baseUrl = new URL(url.slice(4)); let baseUrl = new URL(url.slice(4));
baseUrl.searchParams.set("api_updates", "true"); baseUrl.searchParams.set("api_updates", "true");
await this.monitorDevServer(baseUrl); await this.monitorDevServer(baseUrl);