Skip to content

Commit

Permalink
fix: resolve headers when cross fetch is not available in environment
Browse files Browse the repository at this point in the history
  • Loading branch information
vasco-santos committed Oct 22, 2021
1 parent b9db70a commit 8fbb6aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const resolveHeaders = (headers: Dom.RequestInit['headers']): Record<string, str
if (headers) {
if (
(typeof Headers !== 'undefined' && headers instanceof Headers) ||
headers instanceof CrossFetch.Headers
(CrossFetch.Headers && headers instanceof CrossFetch.Headers)
) {
oHeaders = HeadersInstanceToPlainObject(headers)
} else if (Array.isArray(headers)) {
Expand Down

0 comments on commit 8fbb6aa

Please sign in to comment.