Skip to content

Commit

Permalink
ZooniverseClient: abandonSubjectInMainThread: Check for nil subject.
Browse files Browse the repository at this point in the history
This should not happen but maybe it is happening, causing the exception
seen in the occasional crashes when pressing the revert button.
See #21
  • Loading branch information
murraycu committed May 30, 2016
1 parent 2f9db0f commit 05cb6fb
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ios-galaxyzoo/client/ZooniverseClient.m
Original file line number Diff line number Diff line change
Expand Up @@ -1138,6 +1138,10 @@ - (void)deleteImagesForSubject:(ZooniverseSubject *)subject
- (void)abandonSubjectInMainThread:(ZooniverseSubject *)subject
withCoreDataSave:(BOOL)coreDataSave
{
if (subject == nil) {
NSLog(@"abandonSubject: subject is nil.");
}

NSLog(@"abandonSubject: Abandoning subject with subjectId: %@", subject.subjectId, nil);

//Start asynchronous deletion of the image files.
Expand Down

0 comments on commit 05cb6fb

Please sign in to comment.