修复AccessPlatformAPIWithRetry中bodyGeneral可能为nil的bug
This commit is contained in:
@@ -166,7 +166,7 @@ func AccessPlatformAPIWithRetry(client *http.Client, handleRequest func() *http.
|
|||||||
// 临时处理返回值居然不是map的情况
|
// 临时处理返回值居然不是map的情况
|
||||||
if bodyMap2, ok := bodyGeneral.(map[string]interface{}); ok {
|
if bodyMap2, ok := bodyGeneral.(map[string]interface{}); ok {
|
||||||
bodyMap = bodyMap2
|
bodyMap = bodyMap2
|
||||||
} else {
|
} else if bodyGeneral != nil {
|
||||||
bodyMap = map[string]interface{}{
|
bodyMap = map[string]interface{}{
|
||||||
KeyData: bodyGeneral,
|
KeyData: bodyGeneral,
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user