Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

App crashing when you pass in a nil as value on the dict #26

Open
wants to merge 1 commit into from

1 participant

senior7515
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on May 22, 2012
  1. senior7515
This page is out of date. Refresh to see the latest.
Showing with 2 additions and 1 deletion.
  1. +2 −1  Classes/YAJLDocument.m
3  Classes/YAJLDocument.m
View
@@ -97,7 +97,8 @@ - (void)parser:(YAJLParser *)parser didAdd:(id)value {
break;
case YAJLDecoderCurrentTypeDict:
NSParameterAssert(key_);
- [dict_ setObject:value forKey:key_];
+ if(value!=nil)
+ [dict_ setObject:value forKey:key_];
if ([delegate_ respondsToSelector:@selector(document:didSetObject:forKey:inDictionary:)])
[delegate_ document:self didSetObject:value forKey:key_ inDictionary:dict_];
[self _popKey];
Something went wrong with that request. Please try again.