summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLLLL Colonq <llll@colonq>2024-11-14 21:54:55 -0500
committerLLLL Colonq <llll@colonq>2024-11-14 21:54:55 -0500
commit2975b7e20a35ecaff0619af133068238021a8c5b (patch)
tree600db1952e4de85ed4be323cf96e7f4a75ad71c6
parente7d4b428708b0fa74140a7a0af7d4cab1912bdf4 (diff)
Add some logging
-rw-r--r--fig-web/src/Fig/Web.hs2
1 files changed, 2 insertions, 0 deletions
diff --git a/fig-web/src/Fig/Web.hs b/fig-web/src/Fig/Web.hs
index 5d32f75..37a1991 100644
--- a/fig-web/src/Fig/Web.hs
+++ b/fig-web/src/Fig/Web.hs
@@ -96,9 +96,11 @@ app cfg cmds liveEvents currentlyLive = do
let user = Text.toLower auth.name
LDAP.resetUserPassword cfg user auth.id >>= \case
Nothing -> do
+ log "Failed to register user"
Sc.status status500
Sc.text "failed to register"
Just pass -> do
+ log "Successfully registered user, responding..."
Sc.text . Text.L.fromStrict $ user <> " " <> pass
Sc.get "/api/check" $ authed cfg \auth -> do
Sc.json @[Text] [auth.id, auth.name]