Add boolean state hook

Signed-off-by: Tilman Vatteroth <git@tilmanvatteroth.de>
This commit is contained in:
Tilman Vatteroth 2022-07-08 20:30:11 +02:00
parent 311d37b16f
commit 50d2dee9d2
15 changed files with 114 additions and 118 deletions

View file

@ -37,11 +37,7 @@ export const AccessTokenDeletionModal: React.FC<AccessTokenDeletionModalProps> =
)
})
.catch(showErrorNotification('profile.modal.deleteAccessToken.failed'))
.finally(() => {
if (onHide) {
onHide()
}
})
.finally(() => onHide?.())
}, [token, onHide])
return (