             object: nil,
             queue: NSOperationQueue.mainQueue(),
             usingBlock: { _ in
-                self.showNetworkErrorAlert()
+                if NSDate().timeIntervalSinceDate(self.lastAlertTime) > NSTimeInterval(5) {
+                    self.showNetworkErrorAlert()
+                }
                 if !CredentialManager.sharedInstance.hasCredentials() {
                     self.presentLoginView()
                 }

            delegate: self,
            cancelButtonTitle: NSLocalizedString("Dismiss", comment: "Button to dismiss network error message box")
        )
        alert.show()
    }
}


class MainTabBarController : UITabBarController {
    
    // Ensure first alert is always shown
    var lastAlertTime = NSDate(timeIntervalSince1970: 0)
    
    override func viewDidLoad() {
        super.viewDidLoad()
        self.view.backgroundColor = UIColor.whiteColor()
