I'm building an iOS app.I have implemented Facebook and twitter integration in my app.
I am facing an problem in a viewcontroller i have button Next and implemented a push segue on that button to go on next view,but my app crashed when i click on the Next button and got an error.
Error:Terminating app due to uncaught exception 'NSGenericException', reason: 'Could not find a navigation controller for segue 'nextSport'. Push segues can only be used when the source controller is managed by an instance of UINavigationController.'
Here is Screenshot of storyboards:
Previous Image:

Present(new) image added:

This is my code:
- (IBAction)fbLogin:(id)sender {
[FBSession openActiveSessionWithReadPermissions:@[@"email",@"user_location",@"user_birthday",@"user_hometown"]
allowLoginUI:YES
completionHandler:^(FBSession *session, FBSessionState state, NSError *error) {
switch (state) {
case FBSessionStateOpen:
[[FBRequest requestForMe] startWithCompletionHandler:^(FBRequestConnection *connection, NSDictionary<FBGraphUser> *user, NSError *error) {
if (error) {
NSLog(@"error:%@",error);
}
else
{
// retrive user's details at here as shown below
[[FBRequest requestForMe] startWithCompletionHandler:^(FBRequestConnection *connection, NSDictionary<FBGraphUser> *FBuser, NSError *error) {
if (error) {
// Handle error
}
else {
NSString *userName = [FBuser name];
NSLog(@"username===%@",userName);
NSLog(@"sesseion=%@",session);
}
}];
NSLog(@"FB user first name:%@",user.first_name);
userName=user.first_name;
NSLog(@"FB user last name:%@",user.last_name);
NSLog(@"FB user birthday:%@",user.birthday);
NSLog(@"FB user location:%@",user.location);
NSLog(@"FB user username:%@",user.username);
NSLog(@"FB user gender:%@",[user objectForKey:@"gender"]);
NSLog(@"email id:%@",[user objectForKey:@"email"]);
NSLog(@"location:%@", [NSString stringWithFormat:@"Location: %@\n\n",
user.location[@"name"]]);
userImageURL = [NSString stringWithFormat:@"https://graph.facebook.com/%@/picture?type=large", [user objectID]];
NSLog(@"image=%@",userImageURL);
}
[self performSegueWithIdentifier:@"afterLogin" sender:nil];
}];
break;
}
} ];
}