سؤال

- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
     if ([[segue identifier] isEqualToString:@"ShowWordDetailsTwo"]) {
        NSIndexPath *indexPath = nil;
        Words *word = nil;
        indexPath = [self.tableView indexPathForSelectedRow];
        word = [myFavsTwo objectAtIndex:indexPath.row];

         DetailsViewController *destViewController = segue.destinationViewController;
         destViewController.word = word;
    }
}

I'm getting a crash on segue -- breakpoint at:

     destViewController.word = word;

but if I "continue" on my debugger everything will work as normal -- the app just seems to be getting hung up on this line...

I think it's got to do with my object being part of NSUserDefaults with NSCoder...

how can I make it so that the app doesn't crash?!

I'm not getting any error message just a break point error

هل كانت مفيدة؟

المحلول

Just clarifying,

Did you create the breakpoint yourself, or was it autocreated by the debugger?

Try disabling the breakpoint to see if it works.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top