aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineUpdateViewVM.cs
diff options
context:
space:
mode:
authorShlomo Hecht <shlomo@twine-s.com>2019-03-13 10:56:17 +0200
committerShlomo Hecht <shlomo@twine-s.com>2019-03-13 10:56:17 +0200
commit8df72202be31480ecd82d475523a8708c34ebd53 (patch)
tree7cb865092804e8a224cc7e15a525d2d960c0b462 /Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineUpdateViewVM.cs
parentce5f4c3f8e985095fa287d41cefef86b97f0a76d (diff)
parentf220013b518c49989ded8be13e12bfa82837f634 (diff)
downloadTango-8df72202be31480ecd82d475523a8708c34ebd53.tar.gz
Tango-8df72202be31480ecd82d475523a8708c34ebd53.zip
Merge branch 'master' of https://twinetfs.visualstudio.com/Tango/_git/Tango
Diffstat (limited to 'Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineUpdateViewVM.cs')
-rw-r--r--Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineUpdateViewVM.cs8
1 files changed, 8 insertions, 0 deletions
diff --git a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineUpdateViewVM.cs b/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineUpdateViewVM.cs
index b5b5f56bc..07da99818 100644
--- a/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineUpdateViewVM.cs
+++ b/Software/Visual_Studio/PPC/Tango.PPC.UI/ViewModels/MachineUpdateViewVM.cs
@@ -33,6 +33,7 @@ namespace Tango.PPC.UI.ViewModels
private MachineUpdateResult _update_result;
private DbCompareResult _db_compare_result;
+ private bool _isChecking;
#region Properties
@@ -132,8 +133,11 @@ namespace Tango.PPC.UI.ViewModels
{
await NavigateTo(MachineUpdateView.UpdateCheckView);
+ if (_isChecking) return;
+
try
{
+ _isChecking = true;
IsDbUpdate = false;
var response = await MachineUpdateManager.CheckForUpdate(MachineProvider.Machine.SerialNumber);
@@ -164,6 +168,10 @@ namespace Tango.PPC.UI.ViewModels
LogManager.Log(ex, "Error while trying to check for updates.");
await NavigateTo(MachineUpdateView.UpdateFailedView);
}
+ finally
+ {
+ _isChecking = false;
+ }
}
private async void Update()