Redirect applicants to verify their emails

This commit is contained in:
Saku Laesvuori 2023-09-27 15:22:39 +03:00
parent 3d3b5d6bd2
commit 8792b9dde6
Signed by: slaesvuo
GPG Key ID: 257D284A2A1D3A32
1 changed files with 2 additions and 2 deletions

View File

@ -80,7 +80,7 @@ postApplyR :: (YesodAuth DataIdClient, AuthId DataIdClient ~ Text) => Handler Ht
postApplyR = do
((result, widget), enctype) <- runFormPost applyForm
case result of
FormSuccess application -> apiRequest @Apply False application >>= \x ->
redirect $ ProfileR $ let ApplyApply {..} = apply x in id
FormSuccess application -> apiRequest @Apply False application >> redirect VerifyEmailR
-- TODO: Automatically log in
_ -> do
defaultLayout $ applyW (widget, enctype)