Actually respect the user's wish not to check for updates #2919

This commit is contained in:
James Cole 2019-12-27 08:07:07 +01:00
parent 017fa5a917
commit 975b78fc7b
No known key found for this signature in database
GPG Key ID: C16961E655E74B5E

View File

@ -57,6 +57,15 @@ class VersionCheckEventHandler
return;
}
// should not check for updates:
$permission = app('fireflyconfig')->get('permission_update_check', -1);
$value = (int)$permission->data;
if (1 !== $value) {
Log::info('Update check is not enabled.');
return;
}
/** @var UserRepositoryInterface $repository */
$repository = app(UserRepositoryInterface::class);
/** @var User $user */