Skip to content

Commit

Permalink
fix(task_params): don't check params for ansible
Browse files Browse the repository at this point in the history
  • Loading branch information
fiftin committed Jul 15, 2024
1 parent c0491e7 commit faa71a0
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions web/src/components/TaskParamsForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,6 @@
<script>
const APP_PARAMS = {
ansible: ['debug', 'dry_run', 'diff'],
terraform: ['plan', 'auto_approve'],
tofu: ['plan', 'auto_approve'],
};
Expand All @@ -81,10 +80,12 @@ export default {
updateValue(prop, value) {
let input = { ...this.value, [prop]: value };
input = (APP_PARAMS[this.app] || []).reduce((res, param) => ({
...res,
[param]: input[param],
}), {});
if (APP_PARAMS[this.app]) {
input = (APP_PARAMS[this.app] || []).reduce((res, param) => ({
...res,
[param]: input[param],
}), {});
}
this.$emit('input', input);
},
Expand Down

0 comments on commit faa71a0

Please sign in to comment.