1
0
Fork 0
mirror of https://github.com/Yetangitu/ampache synced 2025-10-04 18:29:40 +02:00

Fix up the tests a bit

The hash check shouldn't be mixed in with the version check, and we now
need JSON.
This commit is contained in:
Paul Arthur 2013-02-03 04:24:08 -05:00
parent 287ddc4345
commit 10d54c9f7f
3 changed files with 38 additions and 48 deletions

View file

@ -26,22 +26,11 @@
* sure that it's good enough
*/
function check_php_ver($level=0) {
if (floatval(phpversion()) < 5.3) {
return false;
}
// Make sure that they have the sha256() algo installed
if (!function_exists('hash_algos')) { return false; }
$algos = hash_algos();
if (!in_array('sha256',$algos)) {
return false;
}
return true;
} // check_php_ver
}
/**
* check_php_session
@ -58,21 +47,6 @@ function check_php_session() {
} // check_php_session
/**
* check_php_pcre
* This makes sure they have pcre (preg_???) support
* compiled into PHP this is required!
*/
function check_php_pcre() {
if (!function_exists('preg_match')) {
return false;
}
return true;
} // check_php_pcre
/**
* check_pdo
*