chore(oauth2): remove unused loadPlugin function

This commit is contained in:
Sarah Vaupel 2024-03-21 09:16:43 +01:00
parent 0599ec2512
commit 795c707a1f

View File

@ -355,12 +355,12 @@ makeFoundation appSettings''@AppSettings{..} = do
]
#else
let -- Auth Plugins
loadPlugin p prefix = do -- Loads given YesodAuthPlugin
mID <- fmap Text.pack <$> appUserAuthConf ^? _UserAuthConfSingleSource . _AuthSourceConfAzureAdV2 . _azureConfClientId
mSecret <- fmap Text.pack <$> appUserAuthConf ^? _UserAuthConfSingleSource . _AuthSourceConfAzureAdV2 . _azureConfClientSecret
let mArgs = (,) <$> mID <*> mSecret
guard $ isJust mArgs
return . uncurry p $ fromJust mArgs
-- loadPlugin p prefix = do -- Loads given YesodAuthPlugin
-- mID <- fmap Text.pack <$> appUserAuthConf ^? _UserAuthConfSingleSource . _AuthSourceConfAzureAdV2 . _azureConfClientId
-- mSecret <- fmap Text.pack <$> appUserAuthConf ^? _UserAuthConfSingleSource . _AuthSourceConfAzureAdV2 . _azureConfClientSecret
-- let mArgs = (,) <$> mID <*> mSecret
-- guard $ isJust mArgs
-- return . uncurry p $ fromJust mArgs
tenantID = case appUserAuthConf of
UserAuthConfSingleSource (AuthSourceConfAzureAdV2 AzureConf{..})
-> tshow azureConfTenantId