mirror of https://gitee.com/answerdev/answer.git
fix: tag not exist error
This commit is contained in:
parent
a66cf236ef
commit
72866de5c1
|
@ -263,9 +263,8 @@ func (ts *TagCommonService) UpdateTag(ctx context.Context, tags []string, userID
|
||||||
}
|
}
|
||||||
|
|
||||||
if len(addTagList) > 0 {
|
if len(addTagList) > 0 {
|
||||||
err = fmt.Errorf("add a tag does not exist")
|
err = errors.BadRequest(reason.TagNotFound).WithMsg(fmt.Sprintf("tag [%s] does not exist",
|
||||||
TagMsgList := strings.Replace(strings.Trim(fmt.Sprint(addTagMsgList), "[]"), " ", ",", -1)
|
strings.Join(addTagMsgList, ",")))
|
||||||
errors.BadRequest(reason.TagNotFound).WithMsg(TagMsgList)
|
|
||||||
return err
|
return err
|
||||||
// todo if need add
|
// todo if need add
|
||||||
// err = ts.tagRepo.AddTagList(ctx, addTagList)
|
// err = ts.tagRepo.AddTagList(ctx, addTagList)
|
||||||
|
|
Loading…
Reference in New Issue