diff --git a/business/jxstore/cms/sync.go b/business/jxstore/cms/sync.go index b95a0837c..2ef392172 100644 --- a/business/jxstore/cms/sync.go +++ b/business/jxstore/cms/sync.go @@ -45,7 +45,8 @@ func (v *VendorSync) SyncCategory(db *dao.DaoDB, categoryID int, isForce bool, u if categoryID > 0 { cond[model.FieldID] = categoryID } - if err = dao.GetEntitiesByKV(db, &cats, cond, true); err == nil { + err := dao.GetEntitiesByKV(db, &cats, cond, true) + if err == nil { tasksch.RunTask("", func(batchItemList []interface{}, params ...interface{}) (interface{}, error) { cat := batchItemList[0].(*model.SkuCategory) updateFields := []string{model.FieldJdSyncStatus}