Skip to content

Commit

Permalink
fix edit tags list displaying old values after edit (#133465)
Browse files Browse the repository at this point in the history
(cherry picked from commit 399fca1)
  • Loading branch information
academo committed Jun 3, 2022
1 parent f80ba03 commit 2795c4b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions x-pack/plugins/cases/public/components/tag_list/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,10 @@ export const TagList = React.memo(
const { isValid, data: newData } = await submit();
if (isValid && newData.tags) {
onSubmit(newData.tags);
form.reset({ defaultValue: newData });
setIsEditTags(false);
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [onSubmit, submit]);

const { tags: tagOptions } = useGetTags();
Expand Down

0 comments on commit 2795c4b

Please sign in to comment.