I have a login screen as my root view controller. If the user is already logged in, I want to skip over the login screen and show the main view controller.
The code below does that, but it shows a back button in the nav bar instead of the default nav bar.
Is there a way to remove the back button? There is a menu button that is supposed to be there, so simply hiding the back button will not suffice.
Thanks!
- (void)viewDidLoad {
if(GetUserName != nil){
[self pushingView:YES];
}
[super viewDidLoad];
}
-(void)pushingView:(BOOL)animation{
MainViewController *revealViewController = [self.storyboard instantiateViewControllerWithIdentifier:@"RevealViewController"];
[self.navigationController pushViewController:revealViewController animated:animation];
}