From 7ca12d064da979f840977c70947b8e65f379abb2 Mon Sep 17 00:00:00 2001 From: Sarah Vaupel Date: Sat, 13 Jan 2024 00:40:57 +0100 Subject: [PATCH] refactor(settings): enhance field names --- src/Settings.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Settings.hs b/src/Settings.hs index 3e1790b2e..753dd56d0 100644 --- a/src/Settings.hs +++ b/src/Settings.hs @@ -299,7 +299,7 @@ makeLenses_ ''JobMode deriveFromJSON defaultOptions { constructorTagModifier = camelToPathPiece' 2 - , sumEncoding = TaggedObject "type" "config" + , sumEncoding = TaggedObject "protocol" "config" } ''UserDbConf instance FromJSON HaskellNet.PortNumber where @@ -604,7 +604,7 @@ instance FromJSON AppSettings where Ldap.Tls host _ -> not $ null host Ldap.Plain host -> not $ null host nonEmptyHost (UserDbOAuth2 OAuth2Conf{..}) = not $ or [ null oauth2TenantId, null oauth2ClientId, null oauth2ClientSecret ] - appUserDbConf <- P.fromList . mapMaybe (assertM nonEmptyHost) <$> o .:? "user-db" .!= [] + appUserDbConf <- P.fromList . mapMaybe (assertM nonEmptyHost) <$> o .:? "user-databases" .!= [] appLmsConf <- o .: "lms-direct" appAvsConf <- assertM (not . null . avsPass) <$> o .:? "avs" appLprConf <- o .: "lpr"