Changed how version information is stored and displayed

This commit is contained in:
Bernd Bestel
2018-05-12 15:49:21 +02:00
parent 5b5c272909
commit 89bae8d25e
6 changed files with 15 additions and 13 deletions

View File

@@ -13,14 +13,11 @@ class ApplicationService extends BaseService
}
private $InstalledVersion;
/**
* @return string
*/
public function GetInstalledVersion()
{
if ($this->InstalledVersion == null)
{
$this->InstalledVersion = preg_replace("/\r|\n/", '', file_get_contents(__DIR__ . '/../version.txt'));
$this->InstalledVersion = json_decode(file_get_contents(__DIR__ . '/../version.json'));
}
return $this->InstalledVersion;