fix: don't pass db error

This commit is contained in:
Derrick Hammer 2024-03-26 20:21:34 -04:00
parent ea5a97c613
commit 5a9f4a5940
Signed by: pcfreak30
GPG Key ID: C997C339BE476FF2
1 changed files with 1 additions and 1 deletions

View File

@ -202,7 +202,7 @@ func (s AccountServiceDefault) VerifyEmail(email string, token string) error {
if result.Error != nil { if result.Error != nil {
if errors.Is(result.Error, gorm.ErrRecordNotFound) { if errors.Is(result.Error, gorm.ErrRecordNotFound) {
return NewAccountError(ErrKeyEmailVerificationFailed, result.Error) return NewAccountError(ErrKeyEmailVerificationFailed, nil)
} }
return NewAccountError(ErrKeyDatabaseOperationFailed, result.Error) return NewAccountError(ErrKeyDatabaseOperationFailed, result.Error)