AI代码生成工具

This commit is contained in:
李琦
2026-08-10 15:51:00 +08:00
parent d0018a0173
commit bd226c260f
31 changed files with 5468 additions and 31 deletions

View File

@@ -397,7 +397,7 @@ if(!function_exists('ase_encode')) {
function ase_encode($str)
{
if (empty($str)) return $str;
return base64_encode(\Illuminate\Support\Str::random(config('ase.len')). base64_encode($str));
return base64_encode(\Illuminate\Support\Str::random(config('nl.ase_len', 30)). base64_encode($str));
}
}
@@ -411,7 +411,7 @@ if (!function_exists('ase_decode')) {
{
if (empty($str)) return $str?? '';
$result = base64_decode($str);
$result = base64_decode(substr($result, config('ase.len')));
$result = base64_decode(substr($result, config('nl.ase_len', 30)));
$pattern = '/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\xFF]|[\x{E000}-\x{F8FF}]/u';
if (preg_match($pattern, $result)) return $str;
return $result;