Skip to content

Commit

Permalink
Merge pull request #129 from openimis/hotfix/fix-enquiry
Browse files Browse the repository at this point in the history
fix: fix typo
  • Loading branch information
wzglinieckisoldevelo authored Mar 4, 2024
2 parents 9a48db1 + 3ee8447 commit 8db5af3
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/components/EnquiryDialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,15 +34,15 @@ const EnquiryDialog = ({
error,
onClose,
open,
chfId,
chfid,
match,
}) => {
const classes = useStyles();
const prevMatchUrl = useRef(null);

useEffect(() => {
if (open && insuree?.id !== chfId) {
fetchInsuree(modulesManager, chfId);
if (open && insuree?.id !== chfid) {
fetchInsuree(modulesManager, chfid);
}

if (!!match?.url && match.url !== prevMatchUrl.current) {
Expand All @@ -52,7 +52,7 @@ const EnquiryDialog = ({
if (!!match?.url) {
prevMatchUrl.current = match.url;
}
}, [open, chfId, match?.url]);
}, [open, chfid, match?.url]);

return (
<Dialog maxWidth="xl" fullWidth open={open} onClose={onClose}>
Expand All @@ -62,7 +62,7 @@ const EnquiryDialog = ({
<Error
error={{
code: formatMessage(intl, "insuree", "notFound"),
detail: formatMessageWithValues(intl, "insuree", "chfIdNotFound", { chfId }),
detail: formatMessageWithValues(intl, "insuree", "chfIdNotFound", { chfid }),
}}
/>
)}
Expand Down

0 comments on commit 8db5af3

Please sign in to comment.