mirror of
https://github.com/appwrite/appwrite
synced 2026-05-24 09:28:40 +00:00
Merge pull request #2544 from appwrite/fix-health-av-response
fix: throw exception when antivirus is not available
This commit is contained in:
commit
d78c279b34
1 changed files with 1 additions and 2 deletions
|
|
@ -341,8 +341,7 @@ App::get('/v1/health/anti-virus')
|
||||||
$output['version'] = @$antivirus->version();
|
$output['version'] = @$antivirus->version();
|
||||||
$output['status'] = (@$antivirus->ping()) ? 'pass' : 'fail';
|
$output['status'] = (@$antivirus->ping()) ? 'pass' : 'fail';
|
||||||
} catch( \Exception $e) {
|
} catch( \Exception $e) {
|
||||||
$output['status'] = 'offline';
|
throw new Exception('Antivirus is not available', 500);
|
||||||
$output['version'] = '';
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue