mirror of
https://github.com/scratchfoundation/scratchjr.git
synced 2024-11-28 18:15:37 -05:00
add md5 nil check
This commit is contained in:
parent
f517e0488a
commit
eefc16b7b7
1 changed files with 4 additions and 1 deletions
|
@ -313,7 +313,10 @@ NSMutableDictionary *soundtimers;
|
||||||
NSDictionary *page = [json valueForKey:name];
|
NSDictionary *page = [json valueForKey:name];
|
||||||
for (NSString *spriteName in [page valueForKey:@"sprites"]) {
|
for (NSString *spriteName in [page valueForKey:@"sprites"]) {
|
||||||
NSDictionary *sprite = [page valueForKey:spriteName];
|
NSDictionary *sprite = [page valueForKey:spriteName];
|
||||||
[sprites setValue:sprite forKey:[sprite valueForKey:@"md5"]];
|
NSString *md5 = [sprite valueForKey:@"md5"];
|
||||||
|
if (md5 != nil) {
|
||||||
|
[sprites setValue:sprite forKey:md5];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue