BIG-33: fix close drawer when delete bill.

This commit is contained in:
elforjani3
2021-09-12 16:57:08 +02:00
parent 47c38a339e
commit f7b29a260e
2 changed files with 10 additions and 7 deletions

View File

@@ -36,16 +36,13 @@ function BillDetailActionsBar({
// Handle edit bill.
const onEditBill = () => {
return billId
? (history.push(`/bills/${billId}/edit`), closeDrawer('bill-drawer'))
: null;
history.push(`/bills/${billId}/edit`);
closeDrawer('bill-drawer');
};
// Handle delete bill.
const onDeleteBill = () => {
return billId
? (openAlert('bill-delete', { billId }), closeDrawer('bill-drawer'))
: null;
openAlert('bill-delete', { billId });
};
return (