I've just updated Xxode to work with Swift 2.0. As usual, a lot of new problems showed up.
In my app I have a view controller that checks whether the user is logged in and present either login screen or the app's home screen. It's a pretty simple VC:
class WelcomeViewController : UIViewController {
override func viewDidAppear(animated: Bool) {
if PFUser.currentUser() == nil {
self.performSegueWithIdentifier("segue-require-login", sender: self)
}
else {
self.performSegueWithIdentifier("segue-start-app", sender:self);
}
}
}
That used to work perfectly, but now it doesn't. The segue segue-require-login
is of type "Present modally" and it works fine. The segue segue-start-app
is "Show (e.g. Push)", but the view never gets pushed, even though the code is being executed (even prepareForSegue
is called).
I've tried re-creating the segue, performing a Clean, cleaning the project's build folder but nothing seems to help.
Any thoughts?