summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/alert_management/components/alert_details.vue
diff options
context:
space:
mode:
Diffstat (limited to 'app/assets/javascripts/alert_management/components/alert_details.vue')
-rw-r--r--app/assets/javascripts/alert_management/components/alert_details.vue26
1 files changed, 16 insertions, 10 deletions
diff --git a/app/assets/javascripts/alert_management/components/alert_details.vue b/app/assets/javascripts/alert_management/components/alert_details.vue
index 1f3fdd5eef2..895c6e76019 100644
--- a/app/assets/javascripts/alert_management/components/alert_details.vue
+++ b/app/assets/javascripts/alert_management/components/alert_details.vue
@@ -140,7 +140,7 @@ export default {
},
currentTabIndex: {
get() {
- return this.$options.tabsConfig.findIndex(tab => tab.id === this.activeTab);
+ return this.$options.tabsConfig.findIndex((tab) => tab.id === this.activeTab);
},
set(tabIdx) {
const tabId = this.$options.tabsConfig[tabIdx].id;
@@ -194,15 +194,21 @@ export default {
projectPath: this.projectPath,
},
})
- .then(({ data: { createAlertIssue: { errors, issue } } }) => {
- if (errors?.length) {
- [this.createIncidentError] = errors;
- this.incidentCreationInProgress = false;
- } else if (issue) {
- visitUrl(this.incidentPath(issue.iid));
- }
- })
- .catch(error => {
+ .then(
+ ({
+ data: {
+ createAlertIssue: { errors, issue },
+ },
+ }) => {
+ if (errors?.length) {
+ [this.createIncidentError] = errors;
+ this.incidentCreationInProgress = false;
+ } else if (issue) {
+ visitUrl(this.incidentPath(issue.iid));
+ }
+ },
+ )
+ .catch((error) => {
this.createIncidentError = error;
this.incidentCreationInProgress = false;
});