AutoUpdater: Use update info for build number instead of trying to parse the version number

the version number might not include the build number, particularly for releases.
This commit is contained in:
Dylan K. Taylor 2018-06-13 18:19:17 +01:00
parent ad7787e13b
commit 37b65aac91

View File

@ -92,7 +92,7 @@ class AutoUpdater{
$newVersion = new VersionString($this->updateInfo["version"]);
$messages = [
"Your version of " . $this->server->getName() . " is out of date. Version " . $newVersion->get(false) . " (build #" . $newVersion->getBuild() . ") was released on " . date("D M j h:i:s Y", $this->updateInfo["date"])
"Your version of " . $this->server->getName() . " is out of date. Version " . $newVersion->get(false) . " (build #" . $this->updateInfo["build"] . ") was released on " . date("D M j h:i:s Y", $this->updateInfo["date"])
];
if($this->updateInfo["details_url"] !== null){
$messages[] = "Details: " . $this->updateInfo["details_url"];