Commit 3435036 chenjie
committed
1 parent 41aa7d8 commit 3435036 Copy full SHA for 3435036
File tree 1 file changed +4
-4
lines changed
1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -9,14 +9,14 @@ import (
9
9
//if error was not in this error's format,code will return -1,msg will use the origin error.Error()
10
10
11
11
type Error struct {
12
- Code int64 `json:"code"`
12
+ Code int32 `json:"code"`
13
13
Msg string `json:"msg"`
14
14
}
15
15
16
- func MakeError (code int64 , msg string ) * Error {
16
+ func MakeError (code int32 , msg string ) * Error {
17
17
return & Error {Code : code , Msg : msg }
18
18
}
19
- func GetCodeFromErrorstr (e string ) int64 {
19
+ func GetCodeFromErrorstr (e string ) int32 {
20
20
if e == "" {
21
21
return 0
22
22
}
@@ -26,7 +26,7 @@ func GetCodeFromErrorstr(e string) int64 {
26
26
}
27
27
return tempe .Code
28
28
}
29
- func GetCodeFromStdError (e error ) int64 {
29
+ func GetCodeFromStdError (e error ) int32 {
30
30
if e == nil {
31
31
return 0
32
32
}
You can’t perform that action at this time.
0 commit comments