aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UpdateService/MachineStudioUpdateService.svc.cs
diff options
context:
space:
mode:
authorShlomo Hecht <shlomo@twine-s.com>2018-08-02 10:24:54 +0300
committerShlomo Hecht <shlomo@twine-s.com>2018-08-02 10:24:54 +0300
commit66aa9beeec79e5f828fc13ce7a5e41c15227ec9a (patch)
treea74f7e1b4da57063046177139a5e2db188b13f48 /Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UpdateService/MachineStudioUpdateService.svc.cs
parentad93ce8b0f13540aafe55bc3ba9d7d72aa1fc7e2 (diff)
parent9e979a9b18727fdc9f128da5a7d2347dff2d0705 (diff)
downloadTango-66aa9beeec79e5f828fc13ce7a5e41c15227ec9a.tar.gz
Tango-66aa9beeec79e5f828fc13ce7a5e41c15227ec9a.zip
Merge branch 'master' of https://twinetfs.visualstudio.com/_git/Tango
Diffstat (limited to 'Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UpdateService/MachineStudioUpdateService.svc.cs')
-rw-r--r--Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UpdateService/MachineStudioUpdateService.svc.cs4
1 files changed, 3 insertions, 1 deletions
diff --git a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UpdateService/MachineStudioUpdateService.svc.cs b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UpdateService/MachineStudioUpdateService.svc.cs
index 9ec234449..3320a86c7 100644
--- a/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UpdateService/MachineStudioUpdateService.svc.cs
+++ b/Software/Visual_Studio/MachineStudio/Tango.MachineStudio.UpdateService/MachineStudioUpdateService.svc.cs
@@ -67,6 +67,8 @@ namespace Tango.MachineStudio.UpdateService
var latestVersion = db.MachineStudioVersions.ToList().OrderByDescending(x => Version.Parse(x.Version)).FirstOrDefault();
Version currentVersion = Version.Parse(request.Version);
+ bool isForcedUpdate = db.MachineStudioVersions.ToList().Exists(x => x.ForceUpdate && Version.Parse(x.Version) > currentVersion);
+
if (latestVersion != null && Version.Parse(latestVersion.Version) > currentVersion)
{
response.IsUpdateAvailable = true;
@@ -76,7 +78,7 @@ namespace Tango.MachineStudio.UpdateService
response.Password = ConfigurationManager.AppSettings["Password"].ToString();
response.FilePath = latestVersion.FtpFilePath;
response.Version = latestVersion.Version;
- response.ForcedUpdate = latestVersion.ForceUpdate;
+ response.ForcedUpdate = isForcedUpdate;
}
}
else