We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
fetch
1 parent 209b1f1 commit a5c8b5bCopy full SHA for a5c8b5b
packages/sdk/src/index.ts
@@ -130,7 +130,7 @@ export class PayloadSDK<T extends PayloadGeneratedTypes = PayloadGeneratedTypes>
130
fetch: typeof fetch
131
constructor(args: Args) {
132
this.baseURL = args.baseURL
133
- this.fetch = args.fetch ?? globalThis.fetch
+ this.fetch = args.fetch ?? globalThis.fetch.bind(globalThis)
134
this.baseInit = args.baseInit ?? {}
135
}
136
0 commit comments