Skip to content

Commit

Permalink
[Metrics UI] Fix removing warning threshold from alert expressions (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Zacqary authored Mar 3, 2021
1 parent 37c5da4 commit 780febd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ export const Expressions: React.FC<Props> = (props) => {
const updateParams = useCallback(
(id, e: InventoryMetricConditions) => {
const exp = alertParams.criteria ? alertParams.criteria.slice() : [];
exp[id] = { ...exp[id], ...e };
exp[id] = e;
setAlertParams('criteria', exp);
},
[setAlertParams, alertParams.criteria]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ export const Expressions: React.FC<Props> = (props) => {
const updateParams = useCallback(
(id, e: MetricExpression) => {
const exp = alertParams.criteria ? alertParams.criteria.slice() : [];
exp[id] = { ...exp[id], ...e };
exp[id] = e;
setAlertParams('criteria', exp);
},
[setAlertParams, alertParams.criteria]
Expand Down

0 comments on commit 780febd

Please sign in to comment.