Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialRyan Settles
3,881 PointsSelf-destructing Messaging App Failing
After completing the Viewing Videos Using MPMoviePlayerController portion of the project, my app would not launch on my iPhone 5s. The simulator worked fine. This happened after adding the video sharing capabilities.
After completing the next stage completing the portion where I had to actually destroy the message, everything continued to work fine in the simulator. I logged out to log in as another user and received this error.
Google drive link to error message: https://docs.google.com/document/d/1k4cH7rKxhfkrQgd0mf9CAPzQiv14bOMlcZ37LjIb0mo/edit?usp=sharing
Now the app will not launch in the simulator or iPhone 5s and continues to receive this error. I've uploaded my code to dropbox for anyone to check out. Not sure where to start.
Dropbox link to project: https://www.dropbox.com/s/hrayq7kmkc8a29p/Ribbitz.zip
Any help would be greatly appreciated!
Ryan
2 Answers
Amit Bijlani
Treehouse Guest TeacherIn the prepareForSegue
method of your InboxViewController
you have a weird if
statement. Firstly, it should have an else if
and then there is a misplaced semi-colon. It should really look like the following:
- (void) prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
if ([segue.identifier isEqualToString:@"showLogin"]) {
[segue.destinationViewController setHidesBottomBarWhenPushed:YES];
} else if ([segue.identifier isEqualToString:@"showImage"]) {
[segue.destinationViewController setHidesBottomBarWhenPushed:YES];
ImageViewController *imageViewController = (ImageViewController *)segue.destinationViewController;
imageViewController.message = self.selectedMessage;
}
}
Ryan Settles
3,881 PointsThanks for your time Amit. It works!