refactor(2127): hidden displaying popup after card deletion

keep-around/b88963f3f008d7c1cb5ea6148a98898d73598337
Mirlan 4 years ago
parent 401f962290
commit b88963f3f0
  1. 1
      Makefile
  2. 7
      src/features/CardsStore/hooks/index.tsx

@ -2,6 +2,7 @@ install:
npm install
develop:
REACT_APP_TYPE=ott \
REACT_APP_CLIENT=instat \
npm start

@ -38,12 +38,7 @@ export const useBankCards = () => {
.then(fetchCards)
)
const onDeleteCard = async (cardId: string) => {
await deleteCard(cardId).then(() => {
fetchCards()
toggleInfoModal()
})
}
const onDeleteCard = (cardId: string) => deleteCard(cardId).then(fetchCards)
const { isFetching, request: handleCardDelete } = useRequest(onDeleteCard)
const onSetDefaultCard = (cardId: string) => {

Loading…
Cancel
Save