Update base.php

This commit is contained in:
Namhyeon Go 2019-04-10 20:08:27 +09:00 committed by GitHub
parent 7d9c3c0841
commit d862d76cbb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -266,6 +266,21 @@ if(!check_function_exists("get_value_in_object")) {
}
}
if(!check_function_exists("check_array_length")) {
functon check_array_length($arr, $len) {
$flag = -1;
$arr_len = count($arr);
if($arr_len == $len) {
$flag = 0;
} elseif($arr_len > $len) {
$flag = 1;
}
return $flag;
}
}
// error handler
if(!check_function_exists("set_error")) {
function set_error($msg, $code="ERROR") {