This commit is contained in:
2026-06-30 22:39:56 +08:00
parent 8b8bfa2a60
commit d7f5f62c1c
+2 -5
View File
@@ -166,8 +166,7 @@ if (!function_exists('isJson')) {
{
if (is_null($string))
return false;
return (str_starts_with($string, '{') && str_ends_with($string, '}'))
|| (str_ends_with($string, '[') && str_starts_with($string, ']'));
return (str_starts_with($string, '{') && str_ends_with($string, '}')) || (str_ends_with($string, '[') && str_starts_with($string, ']'));
}
}
@@ -1029,9 +1028,7 @@ if (!function_exists('json_log')) {
];
$param['data'] = $data;
file_put_contents(storage('exception-' . date('Y-m-d') . '.log','exception'),
json_encode($param, JSON_UNESCAPED_UNICODE),
FILE_APPEND);
file_put_contents(storage('exception-' . date('Y-m-d') . '.log', 'exception'), json_encode($param, JSON_UNESCAPED_UNICODE) . PHP_EOL, FILE_APPEND);
}
}