MugunthKumar/MKNetworkKit — pull request #331 by ewanmellor (2013-05-03 22:16:42+00:00)
Title: Make it possible to prevent the addition of the Accept-Language header.

This adds shouldSendAcceptLanguageHeader to MKNetworkEngine and
MKNetworkOperation (the value on Operation is set by Engine when the
Operation is created).

This defaults to YES, preserving the existing behavior.

If set to NO, then no Accepts-Language header is added to the request.
For API calls that are not language-dependent, this can save a significant
fraction of the request size, since the NSLocale preferredLanguages list
can be long.

This changeset moves the code to set the Accepts-Language header out of
MKNetworkOperation initWithURLString and into
connection:willSendRequest:redirectResponse:. This is necessary because
NSURLConnection sets a default Accepts-Language: en-us header if you
try to omit it. You have to explicitly delete it again before the
request is sent.