TunnelViewModel: Don't call peer change handler if there are no changes

Signed-off-by: Roopesh Chander <roop@roopc.net>
This commit is contained in:
Roopesh Chander 2019-02-04 18:57:59 +05:30
parent 657ec34d19
commit 8a6a60482c
1 changed files with 3 additions and 1 deletions

View File

@ -462,9 +462,11 @@ class TunnelViewModel {
}
}
scratchpad = otherScratchPad
if !changes.isEmpty {
changeHandler(peerIndex, changes)
}
}
}
enum SaveResult<Configuration> {
case saved(Configuration)