-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Ensure curl headers are not overwritten but merged in special case. #915
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Do we have the change in the master branch yet? |
Oh bloody hell, I never remember which way round this is meant to be. I'll land it in the morning. Concept wise, this ok? |
Seems reasonable; cc @mamabusi |
This was a good find. The fix looks good too. @swizzlr Once you have a PR on the master, we can merge both. |
@pushkarnk @parkera there you go! |
@swift-ci please test |
1 similar comment
@swift-ci please test |
:( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a conflict marker in this change.
XCTAssert(task.isEqual(task.copy())) | ||
} | ||
<<<<<<< HEAD |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks bad.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bollocks
@alblue fixed! |
The related PR on the master was merged. Once we are done with the code review here, we can merge this. |
Can you squash the bad commit and the fix up instead of leaving it in the history? Otherwise it might break bisect operations.
Sent from my iPhone 📱
… On 14 Mar 2017, at 10:48, Thomas Catterall ***@***.***> wrote:
@alblue fixed!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.
|
Any updates on this one? |
f41efc9
to
1f745ce
Compare
@pushkarnk sorted |
Thanks @swizzlr However, I still see some unrelated code in TestNSURLSession in the patch viz. the tests:
These are related to #911 and #689 which haven't been cherry picked to 3.1 yet. I can see that these come from the commit that added the test case, but I'm not sure how I could help with that. |
@swizzlr @pushkarnk I think this is still important, yeah? |
The related commit was cherry-picked to 3.1 as a part of #970 I am closing this PR. Thanks! |
#637 introduced a subtle bug –
easyHandle.set(customHeaders: [String])
is a straight overwrite, not a merge. This can induce all kinds of headache inducing complexity into an app. Furthermore, it also prevented thecurlHeadersToRemove/Set
functionality from working, leading to undesirableExpect
header assignment.This PR resolves the issue by merging in a
Content-Type
header in the special case.I know it's late in the day but this is really the sort of thing we could do with in 3.1 release.