Răsfoiți Sursa

refactor(Exception): 更新 NotFoundException 异常处理

- 在 NotFoundException 类中引入 error_response 函数
-优化异常处理逻辑,提高错误响应的可定制性
runphp 6 luni în urmă
părinte
comite
76aa8a0563
1 a modificat fișierele cu 1 adăugiri și 0 ștergeri
  1. 1 0
      src/Exception/NotFoundException.php

+ 1 - 0
src/Exception/NotFoundException.php

@@ -4,6 +4,7 @@ namespace SixShop\Core\Exception;
 
 use Exception;
 use think\exception\HttpResponseException;
+use function SixShop\Core\error_response;
 
 class NotFoundException extends HttpResponseException
 {