TunnelsManager: Don't act on status change on tunnelProviders we don't have

That causes errors we don't want, and duplicate notifications.

Signed-off-by: Roopesh Chander <roop@roopc.net>
This commit is contained in:
Roopesh Chander 2018-12-10 17:03:17 +05:30
parent 0d7a585bf7
commit 851bd8102d
1 changed files with 0 additions and 2 deletions

View File

@ -285,8 +285,6 @@ class TunnelsManager {
guard let tunnelProvider = session.manager as? NETunnelProviderManager else { return }
if let tunnel = self?.tunnels.first(where: { $0.tunnelProvider == tunnelProvider }) {
tunnel.tunnelConnectionStatusDidChange()
} else if let tunnelName = tunnelProvider.localizedDescription, let tunnel = self?.tunnel(named: tunnelName) {
tunnel.tunnelConnectionStatusDidChange()
}
}
}