Even less exclamation points.
This commit is contained in:
		
							parent
							
								
									a45fc80ee8
								
							
						
					
					
						commit
						d38c7cb653
					
				
					 1 changed files with 13 additions and 13 deletions
				
			
		| 
						 | 
				
			
			@ -253,7 +253,7 @@ render state
 | 
			
		|||
        Administration -> render_authd_admin_interface
 | 
			
		||||
    -- The footer includes logs and both the WS child components.
 | 
			
		||||
    , Bulma.hr
 | 
			
		||||
    , Bulma.columns_ [ Bulma.column_ [ Bulma.h3 "Logs (watch this if something fails! 😅)", render_logs ]
 | 
			
		||||
    , Bulma.columns_ [ Bulma.column_ [ Bulma.h3 "Logs (watch this if something fails 😅)", render_logs ]
 | 
			
		||||
                     , Bulma.column_ [ render_auth_WS, render_dnsmanager_WS ] ]
 | 
			
		||||
    ]
 | 
			
		||||
  where
 | 
			
		||||
| 
						 | 
				
			
			@ -274,7 +274,7 @@ render state
 | 
			
		|||
    render_setup :: forall monad. MonadAff monad => H.ComponentHTML Action ChildSlots monad
 | 
			
		||||
    render_setup = case state.token of
 | 
			
		||||
                     Just token -> HH.slot _setupi unit SetupInterface.component token SetupInterfaceEvent
 | 
			
		||||
                     Nothing -> Bulma.p "You shouldn't see this page. Reconnect!"
 | 
			
		||||
                     Nothing -> Bulma.p "You shouldn't see this page. Please, reconnect."
 | 
			
		||||
    render_mail_validation :: forall monad. MonadAff monad => H.ComponentHTML Action ChildSlots monad
 | 
			
		||||
    render_mail_validation = HH.slot _mvi unit MVI.component unit MailValidationInterfaceEvent
 | 
			
		||||
    render_zone :: forall monad. String -> MonadAff monad => H.ComponentHTML Action ChildSlots monad
 | 
			
		||||
| 
						 | 
				
			
			@ -310,7 +310,7 @@ render state
 | 
			
		|||
handleAction :: forall o monad. MonadAff monad => Action -> H.HalogenM State Action ChildSlots o monad Unit
 | 
			
		||||
handleAction = case _ of
 | 
			
		||||
  Initialize -> do
 | 
			
		||||
    handleAction $ Log $ SystemLog "Hello, welcome to this application! 🥳"
 | 
			
		||||
    handleAction $ Log $ SystemLog "Hello, welcome to this application. 🥳"
 | 
			
		||||
    sessionstorage <- H.liftEffect $ Window.sessionStorage =<< HTML.window
 | 
			
		||||
    token <- H.liftEffect $ Storage.getItem "user-authd-token" sessionstorage
 | 
			
		||||
    case token of
 | 
			
		||||
| 
						 | 
				
			
			@ -357,7 +357,7 @@ handleAction = case _ of
 | 
			
		|||
 | 
			
		||||
  AuthenticateToAuthd v -> case v of
 | 
			
		||||
    Left token -> do
 | 
			
		||||
      handleAction $ Log $ SystemLog "Authenticate to authd with a token!"
 | 
			
		||||
      handleAction $ Log $ SystemLog "Authenticate to authd with a token."
 | 
			
		||||
      message <- H.liftEffect $ AuthD.serialize $ AuthD.MkAuthByToken { token }
 | 
			
		||||
      H.tell _ws_auth unit (WS.ToSend message)
 | 
			
		||||
    Right (Tuple login password) -> do
 | 
			
		||||
| 
						 | 
				
			
			@ -526,11 +526,11 @@ handleAction = case _ of
 | 
			
		|||
                handleAction $ Routing MailValidation
 | 
			
		||||
              _ -> handleAction $ DispatchAuthDaemonMessage m
 | 
			
		||||
          (AuthD.GotUserEdited u) -> do
 | 
			
		||||
            handleAction $ Log $ SuccessLog $ "User (" <> show u.uid <> ") was modified!"
 | 
			
		||||
            handleAction $ Log $ SuccessLog $ "User (" <> show u.uid <> ") was modified."
 | 
			
		||||
          (AuthD.GotUserValidated _) -> do
 | 
			
		||||
            handleAction $ Log $ SuccessLog "User got validated! You can now log in!"
 | 
			
		||||
            handleAction $ Log $ SuccessLog "User got validated. You can now log in."
 | 
			
		||||
            handleAction $ Routing Authentication
 | 
			
		||||
            handleAction $ AddNotif $ GoodNotification "User got validated! You can now log in!"
 | 
			
		||||
            handleAction $ AddNotif $ GoodNotification "User got validated. You can now log in."
 | 
			
		||||
          (AuthD.GotUsersList _) -> do
 | 
			
		||||
            handleAction $ Log $ ErrorLog "TODO: received a GotUsersList message."
 | 
			
		||||
          (AuthD.GotPermissionCheck _) -> do
 | 
			
		||||
| 
						 | 
				
			
			@ -538,9 +538,9 @@ handleAction = case _ of
 | 
			
		|||
          (AuthD.GotPermissionSet _) -> do
 | 
			
		||||
            handleAction $ Log $ ErrorLog "Received a GotPermissionSet message."
 | 
			
		||||
          m@(AuthD.GotPasswordRecovered _) -> do
 | 
			
		||||
            handleAction $ Log $ SuccessLog "your new password is now valid!"
 | 
			
		||||
            handleAction $ Log $ SuccessLog "your new password is now valid."
 | 
			
		||||
            handleAction $ DispatchAuthDaemonMessage m
 | 
			
		||||
            handleAction $ AddNotif $ GoodNotification "Your new password is now valid!"
 | 
			
		||||
            handleAction $ AddNotif $ GoodNotification "Your new password is now valid."
 | 
			
		||||
          m@(AuthD.GotMatchingUsers _) -> do
 | 
			
		||||
            { current_page } <- H.get
 | 
			
		||||
            case current_page of
 | 
			
		||||
| 
						 | 
				
			
			@ -570,8 +570,8 @@ handleAction = case _ of
 | 
			
		|||
            handleAction $ AddNotif $ BadNotification $ "Sorry, authd sent an error message. "
 | 
			
		||||
              <> maybe "The server didn't tell why." (\v -> "Message was: " <> v) errmsg.reason
 | 
			
		||||
          m@(AuthD.GotPasswordRecoverySent _) -> do
 | 
			
		||||
            handleAction $ Log $ SuccessLog $ "Password recovery: email sent!"
 | 
			
		||||
            handleAction $ AddNotif $ GoodNotification "Your password recovery mail has been sent!"
 | 
			
		||||
            handleAction $ Log $ SuccessLog $ "Password recovery: email sent."
 | 
			
		||||
            handleAction $ AddNotif $ GoodNotification "Your password recovery mail has been sent."
 | 
			
		||||
            handleAction $ DispatchAuthDaemonMessage m
 | 
			
		||||
          (AuthD.GotErrorPasswordTooShort _) -> do
 | 
			
		||||
            handleAction $ Log $ ErrorLog "Password too short!"
 | 
			
		||||
| 
						 | 
				
			
			@ -584,7 +584,7 @@ handleAction = case _ of
 | 
			
		|||
            handleAction $ ToggleAuthenticated Nothing
 | 
			
		||||
            handleAction $ AddNotif $ BadNotification "Invalid credentials!"
 | 
			
		||||
          (AuthD.GotErrorRegistrationsClosed _) -> do
 | 
			
		||||
            handleAction $ Log $ ErrorLog "Registration closed! Try another time or contact an administrator."
 | 
			
		||||
            handleAction $ Log $ ErrorLog "Registration closed. Try another time or contact an administrator."
 | 
			
		||||
            handleAction $ AddNotif $ BadNotification "Registration are closed at the moment."
 | 
			
		||||
          (AuthD.GotErrorInvalidLoginFormat _) -> do
 | 
			
		||||
            handleAction $ Log $ ErrorLog "Invalid login format!"
 | 
			
		||||
| 
						 | 
				
			
			@ -612,7 +612,7 @@ handleAction = case _ of
 | 
			
		|||
            handleAction $ AddNotif $ BadNotification "Invalid renew key!"
 | 
			
		||||
          -- The authentication was a success!
 | 
			
		||||
          (AuthD.GotToken msg) -> do
 | 
			
		||||
            handleAction $ Log $ SuccessLog $ "Authenticated to authd!"
 | 
			
		||||
            handleAction $ Log $ SuccessLog $ "Authenticated to authd."
 | 
			
		||||
            H.modify_ _ { token = Just msg.token }
 | 
			
		||||
            handleAction $ ToggleAuthenticated (Just msg.token)
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		
		Reference in a new issue