Skip to content

Commit

Permalink
fix(csv mapping): rerender on file upload
Browse files Browse the repository at this point in the history
  • Loading branch information
ajohn25 committed Aug 1, 2023
1 parent 480d078 commit 1d0c667
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ const ConfigureColumnMappingDialog: React.FC<ConfigureColumnMappingDialogProps>
};

useEffect(() => {
if (open && !parseComplete && contactsFile) {
if (open && contactsFile) {
Papa.parse(contactsFile, {
header: true,
preview: 2,
Expand All @@ -125,7 +125,7 @@ const ConfigureColumnMappingDialog: React.FC<ConfigureColumnMappingDialogProps>
}
});
}
}, [open, contactsFile]);
}, [contactsFile]);

const handleSave = (formValues: FormValues) => {
const mappedColumns = formValues.columnMappings.filter((column) =>
Expand Down

0 comments on commit 1d0c667

Please sign in to comment.