Skip to content

Commit

Permalink
fix empty spaces bug
Browse files Browse the repository at this point in the history
  • Loading branch information
DanZalov committed Mar 11, 2024
1 parent 7e3dc3a commit ba15694
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/components/TaskForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ if (props.taskId) {
const isNew = !props.taskId
function submitForm() {
newTitle.value = newTitle.value.trim()
if (newTitle.value) {
if (isNew) {
store.addTask({ title: newTitle.value, id: Date.now().toString() })
Expand Down

0 comments on commit ba15694

Please sign in to comment.