Add fallback to email reminder modal (#2193)
* Add fallback to email reminder modal * Add more debug
This commit is contained in:
parent
bf9cedb67b
commit
b1f9454f1d
2 changed files with 17 additions and 0 deletions
|
@ -22,6 +22,7 @@ import {Trans, msg} from '@lingui/macro'
|
|||
import {useLingui} from '@lingui/react'
|
||||
import {useModalControls} from '#/state/modals'
|
||||
import {useSession, useSessionApi, getAgent} from '#/state/session'
|
||||
import {logger} from '#/logger'
|
||||
|
||||
export const snapPoints = ['90%']
|
||||
|
||||
|
@ -45,6 +46,13 @@ export function Component({showReminder}: {showReminder?: boolean}) {
|
|||
const {isMobile} = useWebMediaQueries()
|
||||
const {openModal, closeModal} = useModalControls()
|
||||
|
||||
React.useEffect(() => {
|
||||
if (!currentAccount) {
|
||||
logger.error(`VerifyEmail modal opened without currentAccount`)
|
||||
closeModal()
|
||||
}
|
||||
}, [currentAccount, closeModal])
|
||||
|
||||
const onSendEmail = async () => {
|
||||
setError('')
|
||||
setIsProcessing(true)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue