diff options
author | Roopesh Chander <roop@roopc.net> | 2018-12-11 00:30:33 +0530 |
---|---|---|
committer | Roopesh Chander <roop@roopc.net> | 2018-12-11 00:34:22 +0530 |
commit | 15b6cf541205d935b6afd483af79078c14a21215 (patch) | |
tree | 0a71457f114cb1fcee74b35ab2e8e6d8a7f7bd59 /WireGuard/WireGuard/VPN/TunnelsManager.swift | |
parent | TunnelsManager: Don't act on status change on tunnelProviders we don't have (diff) | |
download | wireguard-apple-15b6cf541205d935b6afd483af79078c14a21215.tar.xz wireguard-apple-15b6cf541205d935b6afd483af79078c14a21215.zip |
Error handling: alertText() can be nil
Indicating that no alert is to be shown for that error.
Signed-off-by: Roopesh Chander <roop@roopc.net>
Diffstat (limited to '')
-rw-r--r-- | WireGuard/WireGuard/VPN/TunnelsManager.swift | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/WireGuard/WireGuard/VPN/TunnelsManager.swift b/WireGuard/WireGuard/VPN/TunnelsManager.swift index b36c9f8..9d04e1f 100644 --- a/WireGuard/WireGuard/VPN/TunnelsManager.swift +++ b/WireGuard/WireGuard/VPN/TunnelsManager.swift @@ -31,7 +31,7 @@ enum TunnelsManagerError: WireGuardAppError { case tunnelActivationFailedInternalError // startTunnel() succeeded, but activation failed case tunnelActivationFailedNoInternetConnection // startTunnel() succeeded, but activation failed since no internet - func alertText() -> (String, String) { + func alertText() -> (String, String)? { switch (self) { case .tunnelNameEmpty: return ("No name provided", "Can't create tunnel with an empty name") |