Skip to content

Commit

Permalink
fixed user verify update on db
Browse files Browse the repository at this point in the history
  • Loading branch information
nikhilnarayanan623 committed Oct 7, 2023
1 parent 9f5dd16 commit a72774a
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions pkg/usecase/auth.go
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,12 @@ func (c *authUseCase) LoginOtpVerify(ctx context.Context, otpVerifyDetails reque
return 0, ErrInvalidOtp
}

if err := c.userRepo.UpdateVerified(ctx, otpSession.UserID); err != nil {

return 0, utils.PrependMessageToError(err, "failed to update user verified in db")

}

return otpSession.UserID, nil
}

Expand Down

0 comments on commit a72774a

Please sign in to comment.