Add more descriptive error message if the title is empty

Signed-off-by: Julius Härtl <jus@bitgrid.net>
This commit is contained in:
Julius Härtl
2020-09-23 09:56:07 +02:00
parent 7bddcb877c
commit ade0e787da

View File

@@ -466,7 +466,7 @@ export default {
}, },
updateTitle(newTitle) { updateTitle(newTitle) {
if (newTitle.trim === '') { if (newTitle.trim === '') {
showError('Could not update card title') showError(t('deck', 'The title cannot be empty.'))
return return
} }
this.$set(this.copiedCard, 'title', newTitle) this.$set(this.copiedCard, 'title', newTitle)