title: NSMutableDictionary: mutating method sent to immutable object
body: <p>The following code is returning an exception with the following error message "mutating method sent to immutable object" when attempting to removeObjectForKey</p>
  
  <pre><code>NSMutableDictionary * storedIpDictionary = (NSMutableDictionary*)[[NSUserDefaults standardUserDefaults] dictionaryForKey:@"dictDeviceIp"];
  
  NSString *key = self.currentDeviceNameText.text;
  NSString *ipAddressTemp = [storedIpDictionary objectForKey:key];
  
  [storedIpDictionary removeObjectForKey:key]; &lt;----Crashes here
  
  storedIpDictionary[key] = ipAddressTemp;
  </code></pre>
  
  <p>Not sure what the issue is, perhaps it is due to retrieving the dictionary from a NSUserDefaults.</p>
  
  <p>However the  following code works without any issues.</p>
  
  <pre><code>NSMutableDictionary * storedIpDictionary = (NSMutableDictionary*)[[NSUserDefaults standardUserDefaults] dictionaryForKey:@"dictDeviceIp"];
  [storedIpDictionary removeAllObjects];
  </code></pre>