From 84d7890ae4644c3a89bc88ca871f76d5b2a49e7c Mon Sep 17 00:00:00 2001 From: Sarah Vaupel Date: Sun, 28 Jan 2024 18:32:14 +0100 Subject: [PATCH] chore(auth): oauth2User->azureUser --- src/Auth/OAuth2.hs | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/Auth/OAuth2.hs b/src/Auth/OAuth2.hs index a810d43e6..c3b775b7a 100644 --- a/src/Auth/OAuth2.hs +++ b/src/Auth/OAuth2.hs @@ -7,7 +7,7 @@ module Auth.OAuth2 ( apAzure , azurePrimaryKey, azureUserPrincipalName, azureUserDisplayName, azureUserGivenName, azureUserSurname, azureUserMail, azureUserTelephone, azureUserMobile, azureUserPreferredLanguage - , oauth2User + , azureUser , AzureUserException(..) , oauth2MockServer , mockPluginName @@ -46,13 +46,13 @@ azureUserPreferredLanguage = "preferredLanguage" -- | User lookup in an OAuth2 database with given credentials -oauth2User :: ( MonadUnliftIO m - -- , MonadThrow m - ) - => AzureConf - -> Creds site - -> m [(Text, [ByteString])] -- (Either AzureUserException [(Text, [ByteString])]) -oauth2User _conf _creds = fmap throwLeft . liftIO . runExceptT $ do +azureUser :: ( MonadUnliftIO m + -- , MonadThrow m + ) + => AzureConf + -> Creds site + -> m [(Text, [ByteString])] -- (Either AzureUserException [(Text, [ByteString])]) +azureUser _conf _creds = fmap throwLeft . liftIO . runExceptT $ do results <- return [] -- TODO case results of [] -> throwE AzureUserNoResult