From 5a9f4a594082789384723d4f6175dfbafe810844 Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Tue, 26 Mar 2024 20:21:34 -0400 Subject: [PATCH] fix: don't pass db error --- account/account.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/account/account.go b/account/account.go index 3a4228b..86535f3 100644 --- a/account/account.go +++ b/account/account.go @@ -202,7 +202,7 @@ func (s AccountServiceDefault) VerifyEmail(email string, token string) error { if result.Error != nil { if errors.Is(result.Error, gorm.ErrRecordNotFound) { - return NewAccountError(ErrKeyEmailVerificationFailed, result.Error) + return NewAccountError(ErrKeyEmailVerificationFailed, nil) } return NewAccountError(ErrKeyDatabaseOperationFailed, result.Error)