feat: 修复requestHandler的BUG

This commit is contained in:
2026-01-03 23:04:32 +08:00
parent 158cf2b33b
commit 1830f0a571

View File

@@ -138,13 +138,12 @@ func (s *server) formatError(ctx *gin.Context, err any) exception.IException {
func (s *server) RequestHandler(uriCfg UriConfig) gin.HandlerFunc {
return func(ctx *gin.Context) {
var (
err error
e exception.IException
handleResult any
inputValue reflect.Value
)
if _, inputValue, e = s.initRequest(ctx, uriCfg); nil != err {
if _, inputValue, e = s.initRequest(ctx, uriCfg); nil != e {
response.SendWithException(ctx, e, &define.ResponseOption{
ContentType: consts.MimeTypeJson,
})