This commit is contained in:
Mrx
2026-02-10 17:37:15 +08:00
parent 25a3b4a761
commit c37cf2b54a
2 changed files with 16 additions and 8 deletions

View File

@@ -44,5 +44,13 @@ func ProcessIVYZX5Q2Request(ctx context.Context, params []byte, deps *processors
}
}
// result==2 时手动抛出错误(不通过/无记录,不返回正常响应)
var ProcessIVYZX5Q2Request struct {
Result int `json:"result"`
}
if err := json.Unmarshal(respBytes, &ProcessIVYZX5Q2Request); err == nil && ProcessIVYZX5Q2Request.Result == 2 {
return nil, errors.Join(processors.ErrNotFound, errors.New("活体检测 result=2 无记录或不通过"))
}
return respBytes, nil
}