From b38d8a2bd89d957d1f3cfd10e733b34bc602d1ed Mon Sep 17 00:00:00 2001 From: Greg Tyler Date: Mon, 20 Nov 2023 09:34:28 +0000 Subject: [PATCH] Reinstate error log I somehow removed this in a previous commit #patch --- lambda/create/main.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lambda/create/main.go b/lambda/create/main.go index 25a2e360..dcd0ab0c 100644 --- a/lambda/create/main.go +++ b/lambda/create/main.go @@ -45,8 +45,10 @@ func (l *Lambda) HandleEvent(ctx context.Context, event events.APIGatewayProxyRe var existingLpa shared.Lpa existingLpa, err := l.store.Get(ctx, uid) if err != nil { + l.logger.Print(err) return shared.ProblemInternalServerError.Respond() } + if existingLpa.Uid == uid { problem := shared.ProblemInvalidRequest problem.Detail = "LPA with UID already exists"