fix: if tag already exists it shouldn't be added to the list

This commit is contained in:
Antonella Sgarlatta
2021-06-09 16:38:53 -03:00
parent b1a4eeed77
commit ead8d5dcf6

View File

@@ -345,6 +345,7 @@ class TagsViewCtrl extends PureViewCtrl<unknown, TagState> {
this.application.alertService!.alert(
"A tag with this name already exists."
);
this.undoCreateTag(newTag);
return;
}
const insertedTag = await this.application.insertItem(newTag);