Refactor Core Update (+8 squashed commit)

Squashed commit:

[b907bb759] Refactor Core Update

[5da2473aa] Refactor Core Update

[3fce45615] Refactor Core Update

[5f050a828] Refactor Core Update

[4b9b85174] Refactor Core Update

[f637ed358] Refactor Core Update

[56543edce] Refactor Core Update

[7f06900ef] Refactor Core Update
This commit is contained in:
Eric
2020-01-03 16:28:17 +01:00
parent 5cdc58846b
commit 864ded2102
12 changed files with 157 additions and 201 deletions

View File

@@ -22,12 +22,6 @@ use utils;
class AjaxController extends Controller
{
public function __construct()
{
parent::__construct();
$this->InitFromModule();
}
public function OperationCanUpdateCore()
{
$aParams = array();
@@ -161,23 +155,6 @@ class AjaxController extends Controller
$this->DisplayJSONPage($aParams, $iResponseCode);
}
public function OperationCheckCompile()
{
$aParams = array();
try
{
CoreUpdater::CheckCompile();
$iResponseCode = 200;
} catch (Exception $e)
{
IssueLog::Error("Compile: ".$e->getMessage());
$aParams['sError'] = $e->getMessage();
$iResponseCode = 500;
}
$this->DisplayJSONPage($aParams, $iResponseCode);
}
public function OperationCompile()
{
$aParams = array();
@@ -185,24 +162,8 @@ class AjaxController extends Controller
{
CoreUpdater::Compile();
$iResponseCode = 200;
} catch (Exception $e)
{
IssueLog::Error("Compile: ".$e->getMessage());
$aParams['sError'] = $e->getMessage();
$iResponseCode = 500;
}
$this->DisplayJSONPage($aParams, $iResponseCode);
}
public function OperationUpdateDatabase()
{
$aParams = array();
try
{
CoreUpdater::UpdateDatabase();
$iResponseCode = 200;
} catch (Exception $e)
catch (Exception $e)
{
IssueLog::Error("Compile: ".$e->getMessage());
$aParams['sError'] = $e->getMessage();