Skip to content
This repository was archived by the owner on Mar 4, 2020. It is now read-only.

Use mutableCopy for many of the fields in copyForRetry. - #365

Open
ewanmellor wants to merge 1 commit into
MKSG-MugunthKumar:masterfrom
tipbit:copyForRetry
Open

Use mutableCopy for many of the fields in copyForRetry.#365
ewanmellor wants to merge 1 commit into
MKSG-MugunthKumar:masterfrom
tipbit:copyForRetry

Conversation

@ewanmellor

Copy link
Copy Markdown

These fields are declared as NSMutableArray / NSMutableDictionary,
so it's violating the type safety to use plain copy.

This is important if you try to cancel an operation that came from
cancelForRetry. [MKNetworkOperation cancel] will clear all the
lists of all the callbacks, which will crash if the lists are not
mutable.

These fields are declared as NSMutableArray / NSMutableDictionary,
so it's violating the type safety to use plain copy.

This is important if you try to cancel an operation that came from
cancelForRetry.  [MKNetworkOperation cancel] will clear all the
lists of all the callbacks, which will crash if the lists are not
mutable.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant