mirror of
https://github.com/scr34m/php-malware-scanner.git
synced 2026-06-16 12:30:35 +00:00
Little return value fix
This commit is contained in:
3
scan.php
3
scan.php
@@ -820,11 +820,12 @@ class MalwareScanner
|
|||||||
{
|
{
|
||||||
$ctx = stream_context_create(array('http' => array('timeout' => 30)));
|
$ctx = stream_context_create(array('http' => array('timeout' => 30)));
|
||||||
|
|
||||||
$latest_hash = trim(file_get_contents($url . '/database/compressed.sha256', false, $ctx));
|
$latest_hash = file_get_contents($url . '/database/compressed.sha256', false, $ctx);
|
||||||
if ($latest_hash === false) {
|
if ($latest_hash === false) {
|
||||||
$this->error('Unable to download database checksum');
|
$this->error('Unable to download database checksum');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
$latest_hash = trim($latest_hash);
|
||||||
|
|
||||||
$file = __DIR__ . '/whitelist.dat';
|
$file = __DIR__ . '/whitelist.dat';
|
||||||
if (is_readable($file)) {
|
if (is_readable($file)) {
|
||||||
|
|||||||
Reference in New Issue
Block a user