diff --git a/package.json b/package.json index 92c82e2..1c21393 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@xtr-dev/rondevu-client", - "version": "0.0.1", + "version": "0.0.2", "description": "TypeScript client for Rondevu peer signaling and discovery server", "main": "dist/index.js", "types": "dist/index.d.ts", diff --git a/src/client.ts b/src/client.ts index bd61004..6c8f5f2 100644 --- a/src/client.ts +++ b/src/client.ts @@ -29,7 +29,7 @@ export class RondevuClient { constructor(options: RondevuClientOptions) { this.baseUrl = options.baseUrl.replace(/\/$/, ''); // Remove trailing slash this.origin = options.origin || new URL(this.baseUrl).origin; - this.fetchImpl = options.fetch || fetch; + this.fetchImpl = options.fetch || globalThis.fetch.bind(globalThis); } /**