Documentation ¶
Index ¶
- Variables
- func CheckVerified(ctx context.Context, db *database.DB, user *User) (context.Context, error)
- func Delete(ctx context.Context, db *database.DB, id int64) error
- func GetCount(db *database.DB) (int, error)
- func NewPasswordReset(db *database.DB, uid int64, secret string) error
- func SettingsUpdatePasswordReset(currentPassword string, newPassword string, user *User, db *database.DB) error
- func UpdatePasswordReset(data *models.NewPasswordFormData, db *database.DB) error
- func VerifyEmail(db *database.DB, uid int64, secret string) error
- func VerifyPasswordReset(db *database.DB, uid string, secret string) error
- type User
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func CheckVerified ¶
func UpdatePasswordReset ¶
func UpdatePasswordReset(data *models.NewPasswordFormData, db *database.DB) error
Types ¶
type User ¶
type User struct { ID int64 `db:"user_id"` Email string `db:"email"` EmailVerified sql.NullTime `db:"email_verified"` EmailVerifySecret string `db:"email_verify_secret"` PasswordHash string `db:"password_hash"` PasswordResetSecret sql.NullString `db:"password_reset_secret"` PasswordResetExp time.Time `db:"password_reset_expires"` LastPasswordChange time.Time `db:"last_password_change"` Created time.Time `db:"created"` LastLogin time.Time `db:"last_login"` LastFailedAttempt sql.NullTime `db:"last_failed_attempt"` FailedAttemptCount uint8 `db:"num_failed_attempts"` OtpSecret sql.NullString `db:"otp_secret"` OtpRecovery sql.NullString `db:"otp_recovery"` OtpAttempts uint8 `db:"otp_recovery_attempts"` ProviderId sql.NullInt64 `db:"provider_id"` Provider *models.Provider }
Click to show internal directories.
Click to hide internal directories.