18 lines
339 B
Go
18 lines
339 B
Go
package storage
|
|
|
|
import "time"
|
|
|
|
type RegistrationLink struct {
|
|
Token string `json:"token"`
|
|
UserID string `json:"userId"`
|
|
CreatedAt time.Time `json:"createdAt"`
|
|
}
|
|
|
|
func NewRegistrationLink(userID string) *RegistrationLink {
|
|
return &RegistrationLink{
|
|
UserID: userID,
|
|
Token: NewID(),
|
|
CreatedAt: time.Now(),
|
|
}
|
|
}
|