diff options
author | Richard Steinmetz <richard@steinmetz.cloud> | 2022-05-28 12:42:45 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-05-28 12:42:45 +0300 |
commit | 2ff376f653d6860b82acf0f450cbd6fabc8355d0 (patch) | |
tree | 54be783bf149de8ae1ed187221b09116916c4bbf | |
parent | 3d05016bc0cc5b1798e560a5c689ae65049ab57e (diff) | |
parent | efe929a5fee2a72b1e783115064e4c4adbe683f6 (diff) |
Merge pull request #6560 from Zivangu9/main
Duplicity validation
-rw-r--r-- | src/components/TagModal.vue | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/components/TagModal.vue b/src/components/TagModal.vue index 6106f7cd1..3e546d866 100644 --- a/src/components/TagModal.vue +++ b/src/components/TagModal.vue @@ -173,7 +173,10 @@ export default { async createTag(event) { this.editing = true const displayName = event.target.querySelector('input[type=text]').value - + if (this.$store.getters.getTags.some(tag => tag.displayName === displayName)) { + showError(this.t('mail', 'Tag already exists')) + return + } try { await this.$store.dispatch('createTag', { displayName, |