Update database.php

This commit is contained in:
Namhyeon Go 2019-04-01 17:29:24 +09:00 committed by GitHub
parent 2bf0f8b17b
commit 5c0dc3cafc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -513,7 +513,7 @@ if(!check_function_exists("json_decode_to_assoc")) {
);
$error = check_invaild_function($invalid_fn);
if($error == -1) {
if($error < 0) {
$obj = @json_decode($data, true);
$result = (@json_last_error() === 0) ? $obj : $result;
}