Replace Echo logger with slog. (#67)

* Replace Echo logger with slog.
This commit is contained in:
Mike Stefanello 2024-06-14 21:01:48 -04:00 committed by GitHub
parent 97bef0257e
commit c8a3d64918
14 changed files with 315 additions and 57 deletions

View file

@ -5,6 +5,7 @@ import (
"fmt"
"github.com/mikestefanello/pagoda/config"
"github.com/mikestefanello/pagoda/pkg/log"
"github.com/labstack/echo/v4"
)
@ -84,7 +85,9 @@ func (m *MailClient) send(email *mail, ctx echo.Context) error {
// Check if mail sending should be skipped
if m.skipSend() {
ctx.Logger().Debugf("skipping email sent to: %s", email.to)
log.Ctx(ctx).Debug("skipping email delivery",
"to", email.to,
)
return nil
}