saloonphp / saloon

🤠 Build beautiful API integrations and SDKs with Saloon
https://docs.saloon.dev
MIT License
2.03k stars 105 forks source link

Connector default headers overwrite request body headers #398

Closed Sammyjo20 closed 1 month ago

Sammyjo20 commented 4 months ago

I recently ran into an issue where my connector had a default Content-Type of application/json and the request had a different Content-Type added by the body trait (HasFormBody) but because of the new PendingRequest order, the connector headers were overwriting the trait's headers.

I think in future versions of Saloon it should work like so:

Sammyjo20 commented 1 month ago

Closing this to clear up the issues, but I will be working on this in v4