修复NewFromMessage错误信息异常问题

This commit is contained in:
zhangdeman committed 2023-09-25 18:49:37 +08:00
1 parent f674702ad2
commit b4732e360b
1 file changed
+1 -1
+1 -1
View File
@@ -125,7 +125,7 @@ func NewFromError(code interface{}, err error) IException {
// Date : 22:25 2023/2/11 // Date : 22:25 2023/2/11
func NewFromMessage(code interface{}, message string) IException { func NewFromMessage(code interface{}, message string) IException {
if len(message) == 0 { if len(message) == 0 {
message = fmt.Sprintf("%v", code) message = getMessage(code, fmt.Sprintf("%v -> 未知异常信息", code))
} }
return NewFromError(code, errors.New(message)) return NewFromError(code, errors.New(message))
} }
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.