Don't reconnect if not necessary
This commit is contained in:
@@ -89,6 +89,7 @@ class MainViewController: UIViewController, SwitchesViewControllerDelegate {
|
||||
{
|
||||
_headerView.xionLogoView.beginAnimating()
|
||||
|
||||
if (!_server.connected) {
|
||||
_updateConnectivityStatus(.Connecting)
|
||||
_server.connect { (error: NSError?) -> Void in
|
||||
if (error == nil) {
|
||||
@@ -99,6 +100,7 @@ class MainViewController: UIViewController, SwitchesViewControllerDelegate {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override func viewDidDisappear(animated: Bool)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user