Slightly more robust configuration polling.

This commit is contained in:
James Cole
2020-07-06 06:49:48 +02:00
parent 4271dc1638
commit 26d19fab32
4 changed files with 32 additions and 25 deletions

View File

@@ -43,8 +43,9 @@ trait UpdateTrait
{
Log::debug('Now in getLatestRelease()');
/** @var UpdateRequestInterface $checker */
$checker = app(UpdateRequestInterface::class);
$channel = app('fireflyconfig')->get('update_channel', 'stable')->data;
$checker = app(UpdateRequestInterface::class);
$channelConfig = app('fireflyconfig')->get('update_channel', 'stable');
$channel = $channelConfig ? $channelConfig->data : 'stable';
return $checker->getUpdateInformation($channel);
}