Add status and success to apply fix events
We want to measure how many apply fixes failed.
Release-Notes: skip
Change-Id: Ic2d913a96638266b386fed6661a9321a05ca4ce9
diff --git a/polygerrit-ui/app/elements/diff/gr-apply-fix-dialog/gr-apply-fix-dialog.ts b/polygerrit-ui/app/elements/diff/gr-apply-fix-dialog/gr-apply-fix-dialog.ts
index 5319c90..3bb89d4 100644
--- a/polygerrit-ui/app/elements/diff/gr-apply-fix-dialog/gr-apply-fix-dialog.ts
+++ b/polygerrit-ui/app/elements/diff/gr-apply-fix-dialog/gr-apply-fix-dialog.ts
@@ -441,6 +441,8 @@
fileExtension: getFileExtension(
this.fixSuggestions?.[0].replacements?.[0].path ?? ''
),
+ success: res.ok,
+ status: res.status,
});
}
}
diff --git a/polygerrit-ui/app/elements/shared/gr-suggestion-diff-preview/gr-suggestion-diff-preview.ts b/polygerrit-ui/app/elements/shared/gr-suggestion-diff-preview/gr-suggestion-diff-preview.ts
index 93f17c8..813ee29 100644
--- a/polygerrit-ui/app/elements/shared/gr-suggestion-diff-preview/gr-suggestion-diff-preview.ts
+++ b/polygerrit-ui/app/elements/shared/gr-suggestion-diff-preview/gr-suggestion-diff-preview.ts
@@ -280,6 +280,8 @@
fixSuggestion?.replacements?.[0].path ?? ''
),
commentId: this.commentId ?? '',
+ success: res.ok,
+ status: res.status,
});
if (res?.ok) {
this.getNavigation().setUrl(