-
-
Notifications
You must be signed in to change notification settings - Fork 102
Closed
Labels
Description
The headers merging logic assumes JavaScript objects and key value pairs. The TypeScript types though allow using fetch Headers. When using fetch Headers, since they're not plain object, anything that sets headers will override them (eg: using a .post with an object as argument, or the .content helper).
I think the easiest fix is to tweak the types as to now allow fetch Headers as argument in the types, but alternatively a slightly smarter merge logic that accounts for Headers object would work too. Threw me in for a loop digging why my authorization headers were going poof right before a post request but not a get.