Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsExistingUser ¶
IsExistingUser examines if an user account is already registered with the given email id.
Types ¶
type User ¶
type User struct {
UserName string `json:"username" bson:"username"`
FirstName string `json:"firstname" bson:"firstname"`
LastName string `json:"lastname" bson:"lastname"`
Name string `json:"name" bson:"name"`
Email string `json:"email" bson:"email"`
Password string `json:"password" bson:"password"`
SubscribeToEmail bool `json:"subscribe" bson:"subscribe"`
Id bson.ObjectId `json:"id" bson:"_id"` // Data type bson.ObjectId is for mongodb bson format
}
User holds basic information regarding site user MongoDB represents JSON documents in binary-encoded format called BSON behind the scenes. BSON extends the JSON model to provide additional data types and to be efficient for encoding and decoding within different languages
func GetUserByEmail ¶
GetUserByEmail returns a user account information if is already registered with the given email id.
Click to show internal directories.
Click to hide internal directories.