chore(foundation): tweak UpsertUserData fields

This commit is contained in:
Sarah Vaupel 2024-03-07 05:37:27 +01:00
parent 77a9100b2e
commit 4feb05a02e

View File

@ -8,7 +8,7 @@ module Foundation.Types
, _upsertUserSource, _upsertUserIdent , _upsertUserSource, _upsertUserIdent
, UpsertUserData(..) , UpsertUserData(..)
, _UpsertUserDataAzure, _UpsertUserDataLdap , _UpsertUserDataAzure, _UpsertUserDataLdap
, _upsertUserAzureConf, _upsertUserAzureData, _upsertUserLdapConf, _upsertUserLdapData , _upsertUserAzureTenantId, _upsertUserAzureData, _upsertUserLdapHost, _upsertUserLdapData
) where ) where
import Import.NoFoundation import Import.NoFoundation
@ -16,6 +16,7 @@ import Import.NoFoundation
import qualified Ldap.Client as Ldap import qualified Ldap.Client as Ldap
-- TODO: rename?
data UpsertUserMode data UpsertUserMode
= UpsertUserLogin { upsertUserSource :: Text } -- TODO: use type synonym? = UpsertUserLogin { upsertUserSource :: Text } -- TODO: use type synonym?
| UpsertUserLoginDummy { upsertUserIdent :: UserIdent } | UpsertUserLoginDummy { upsertUserIdent :: UserIdent }
@ -30,12 +31,12 @@ makePrisms ''UpsertUserMode
data UpsertUserData data UpsertUserData
= UpsertUserDataAzure = UpsertUserDataAzure
{ upsertUserAzureConf :: AzureConf { upsertUserAzureTenantId :: UUID
, upsertUserAzureData :: [(Text, [ByteString])] -- TODO: use type synonym? , upsertUserAzureData :: [(Text, [ByteString])] -- TODO: use type synonym?
} }
| UpsertUserDataLdap | UpsertUserDataLdap
{ upsertUserLdapConf :: LdapConf { upsertUserLdapHost :: Text
, upsertUserLdapData :: Ldap.AttrList [] , upsertUserLdapData :: Ldap.AttrList []
} }
deriving (Show) deriving (Show)