Merge commit '60b405d944254c940f818ebd0b7aa2603d7968a7'

# Conflicts:
#	resources/vanilla
#	src/updater/AutoUpdater.php
This commit is contained in:
Dylan K. Taylor 2020-01-31 19:55:43 +00:00
commit 3e80850938

View File

@ -41,7 +41,7 @@ class AutoUpdater{
protected $server;
/** @var string */
protected $endpoint;
/** @var array|null */
/* @var mixed[]|null */
protected $updateInfo = null;
/** @var VersionString|null */
protected $newVersion;
@ -65,6 +65,8 @@ class AutoUpdater{
/**
* Callback used at the end of the update checking task
*
* @param mixed[] $updateInfo
*/
public function checkUpdateCallback(array $updateInfo) : void{
$this->updateInfo = $updateInfo;
@ -127,6 +129,9 @@ class AutoUpdater{
]);
}
/**
* @param string[] $lines
*/
protected function printConsoleMessage(array $lines, string $logLevel = \LogLevel::INFO) : void{
$title = $this->server->getName() . ' Auto Updater';
$this->logger->log($logLevel, sprintf('----- %s -----', $title));
@ -138,6 +143,8 @@ class AutoUpdater{
/**
* Returns the last retrieved update data.
*
* @return mixed[]|null
*/
public function getUpdateInfo() : ?array{
return $this->updateInfo;