Merge pull request #114 in YUNIONIO/onecloud from ~LIZEXI/onecloud:bugfix/lzx-perform-class-action to release/2.1.0

* commit '40b99ef250b41dfc0f8b0853f18aa76210bac93b':
  performClassActionHandler: handle body is nil
This commit is contained in:
李泽玺
2018-08-25 12:52:43 +08:00
+2 -3
View File
@@ -209,9 +209,8 @@ func performClassActionHandler(ctx context.Context, w http.ResponseWriter, r *ht
if data == nil {
data = body.(*jsonutils.JSONDict)
}
}
if data == nil {
data = body.(*jsonutils.JSONDict)
} else {
data = jsonutils.NewDict()
}
results, err := manager.PerformClassAction(ctx, params["<action>"], query, data)
if err != nil {