feat: add resolver for token verification

Resolves #6
This commit is contained in:
Lakhan Samani
2021-07-14 01:36:11 +05:30
parent 04a522c947
commit eeb8f7d097
9 changed files with 454 additions and 59 deletions

View File

@@ -60,3 +60,13 @@ func (mgr *manager) GetUserByEmail(email string) (User, error) {
return user, nil
}
func (mgr *manager) UpdateVerificationTime(verifiedAt int64, email string) error {
result := mgr.db.Model(&User{}).Where("email = ?", email).Update("email_verified_at", verifiedAt)
if result.Error != nil {
return result.Error
}
return nil
}