add sparse: true for logins

parent 6b441394
......@@ -74,18 +74,21 @@ var UserSchema = new mongoose.Schema({
login: {
type: String,
unique: true
unique: true,
sparse: true
},
password: {
type: String
},
vk_login: {
type: String,
unique: true
unique: true,
sparse: true
},
fb_login: {
type: String,
unique: true
unique: true,
sparse: true
},
accountType: {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment