- ShopCategoryUpdate中不忽略同名错误.

This commit is contained in:
gazebo
2019-09-09 13:52:40 +08:00
parent 5bbde530b0
commit 882c4ff531

View File

@@ -252,11 +252,13 @@ func (a *API) ShopCategoryUpdate(shopID string, categoryID int64, name string, r
"name": name, "name": name,
"rank": rank, "rank": rank,
}) })
if errWithCode, ok := err.(*utils.ErrorWithCode); ok {
if errWithCode.Level() == 0 && errWithCode.IntCode() == 1 { //忽略同名错误 // todo, 之前为什么要忽略同名错误
err = nil // if errWithCode, ok := err.(*utils.ErrorWithCode); ok {
} // if errWithCode.Level() == 0 && errWithCode.IntCode() == 1 { //忽略同名错误
} // err = nil
// }
// }
return err return err
} }