1
0
Fork 0
mirror of synced 2024-05-19 04:02:34 +12:00

Fixed AV health check

This commit is contained in:
Eldad Fux 2021-03-20 09:14:02 +02:00
parent 7443bcf2d8
commit 600692bcac

View file

@ -254,7 +254,10 @@ App::get('/v1/health/anti-virus')
/** @var Appwrite\Utopia\Response $response */
if (App::getEnv('_APP_STORAGE_ANTIVIRUS') === 'disabled') { // Check if scans are enabled
throw new Exception('Anitvirus is disabled');
return $response->json([
'status' => 'disabled',
'version' => '',
]);
}
$antiVirus = new Network(App::getEnv('_APP_STORAGE_ANTIVIRUS_HOST', 'clamav'),