Skip to content

Commit 69f1eed

Browse files
committed
feat(commands): add responses validation
[skip-docker]
1 parent ba7025b commit 69f1eed

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

apps/frontend/src/components/Command.vue

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ const command = toRef(props, 'command');
4444
const commands = toRef(props, 'commands');
4545
const emit = defineEmits<{
4646
(e: 'delete', index: number): void
47-
(e: 'save', index): void
47+
(e: 'save', index: number): void
4848
}>();
4949
5050
const schema = computed(() => yup.object({
@@ -84,7 +84,8 @@ const schema = computed(() => yup.object({
8484
return true;
8585
}),
8686
),
87-
}));
87+
commands: yup.array().required('Responses cannot be empty.'),
88+
}));
8889
8990
async function deleteCommand() {
9091
const index = commands.value.indexOf(command.value);

0 commit comments

Comments
 (0)