mirror of
https://gitee.com/johng/gf.git
synced 2024-11-29 18:57:44 +08:00
improve package gerror
This commit is contained in:
parent
4c54b1cfbc
commit
00d7ee93b2
@ -47,6 +47,9 @@ func (err *Error) Error() string {
|
||||
return ""
|
||||
}
|
||||
errStr := err.text
|
||||
if errStr == "" {
|
||||
errStr = Message(err.code)
|
||||
}
|
||||
if err.error != nil {
|
||||
if err.text != "" {
|
||||
errStr += ": "
|
||||
|
Loading…
Reference in New Issue
Block a user