<commit_before>var mongoose = require('mongoose');

var Member = new mongoose.Schema({
	name: String,
	gender: Number,
	birthday: Date,
	email: String,
	phone: String,
	idno: String,
	password: String,
	salt: String,
	cardno: Number,
	tokens: [ String ],
	awards: [{ type: mongoose.Schema.Types.ObjectId, ref: 'MemberAward' }],
	points: Number,
	created: { type: Date, default: Date.now },
	updated: { type: Date, default: Date.now }
});

Member.methods.validPassword = function(password) {<commit_msg>make email field to be unique<commit_after>var mongoose = require('mongoose');

var Member = new mongoose.Schema({
	name: String,
	gender: Number,
	birthday: Date,
	email: { type: String, unique: true },
	phone: String,
	idno: String,
	password: String,
	salt: String,
	cardno: Number,
	tokens: [ String ],
	awards: [{ type: mongoose.Schema.Types.ObjectId, ref: 'MemberAward' }],
	points: Number,
	created: { type: Date, default: Date.now },
	updated: { type: Date, default: Date.now }
});

Member.methods.validPassword = function(password) {
{'fraction_non_alphanumeric': 0.14846743295019157, 'fraction_numerical': 0.0, 'mean_word_length': 4.9714285714285715, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2832080', 'n_tokens_mistral': 359, 'n_tokens_neox': 362, 'n_words': 100}