mirror of
https://github.com/passepartoutvpn/passepartout-apple.git
synced 2025-01-17 22:19:08 +00:00
Revert to original configuration on tap
This commit is contained in:
parent
be17f57a5e
commit
6ee9f37880
@ -122,7 +122,19 @@ class ConfigurationViewController: UIViewController, TableModelHost {
|
||||
log.warning("Resetting with no original configuration set? Bad table model?")
|
||||
return
|
||||
}
|
||||
// TODO
|
||||
let originalConfiguration: TunnelKitProvider.Configuration
|
||||
do {
|
||||
(_, originalConfiguration) = try TunnelKitProvider.Configuration.parsed(from: url)
|
||||
} catch let e {
|
||||
log.warning("Could not parse original configuration: \(e)")
|
||||
return
|
||||
}
|
||||
initialConfiguration = originalConfiguration
|
||||
configuration = originalConfiguration.builder()
|
||||
itemRefresh.isEnabled = true // allow for manual reconnection
|
||||
tableView.reloadData()
|
||||
|
||||
delegate?.configurationShouldReinstall()
|
||||
}
|
||||
|
||||
@IBAction private func refresh() {
|
||||
|
Loading…
Reference in New Issue
Block a user