From bfd960b7b6ce7b3db75461be4de4a8f19c065f28 Mon Sep 17 00:00:00 2001 From: Nik <45662151+Nikosmonaut@users.noreply.github.com> Date: Mon, 25 Nov 2019 17:11:01 +0100 Subject: [PATCH] Force reward value to 0 when empty field (#11564) --- website/client/src/components/tasks/taskModal.vue | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/website/client/src/components/tasks/taskModal.vue b/website/client/src/components/tasks/taskModal.vue index be135b38fe..8c65d32f66 100644 --- a/website/client/src/components/tasks/taskModal.vue +++ b/website/client/src/components/tasks/taskModal.vue @@ -1437,6 +1437,10 @@ export default { this.task.group.sharedCompletion = this.sharedCompletion; } + if (this.task.type === 'reward' && this.task.value === '') { + this.task.value = 0; + } + if (this.purpose === 'create') { if (this.challengeId) { const response = await this.$store.dispatch('tasks:createChallengeTasks', {