diff options
Diffstat (limited to 'ui-macos/models.py')
-rw-r--r-- | ui-macos/models.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/ui-macos/models.py b/ui-macos/models.py index b5554d3..858975e 100644 --- a/ui-macos/models.py +++ b/ui-macos/models.py @@ -85,6 +85,13 @@ class SshuttleServer(NSObject): def setError_(self, v): self._k_error = v config_changed() + + def isValid(self): + if not self.host(): + return False + if self.autoNets() == NET_MANUAL and not len(list(self.nets())): + return False + return True def host(self): return getattr(self, '_k_host', None) |