Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
.exec()
}
/**
* create a new document
*/
private static async createDoc(): Promise {
const newInfo = new UserVarsModel({ nextUserId: DEFAULT_NEXTUSERID_VALUE })
await newInfo.save()
}
@typegoose.prop()
public nextUserId?: number
}
const UserVarsModel = typegoose.getModelForClass(UserVars)
public rank: number
@typegoose.prop({ default: 1, required: true })
public vipLevel: number
@typegoose.prop({ default: 1, min: 0, max: 7, required: true })
public wins: number
@typegoose.prop({ default: 0, required: true })
public losses: number
@typegoose.prop({ default: 0, required: true })
public kills: number
@typegoose.prop({ default: 0, required: true })
public deaths: number
@typegoose.prop({ default: 0, required: true })
public assists: number
}
const UserModel = typegoose.getModelForClass(User)
@typegoose.prop({ default: new SessionNetworkInfo(), required: true })
public externalNet: SessionNetworkInfo
@typegoose.prop({ default: new SessionNetworkInfo(), required: true })
public internalNet: SessionNetworkInfo
@typegoose.prop({ default: 0, required: true })
public currentChannelServerIndex: number
@typegoose.prop({ default: 0, required: true })
public currentChannelIndex: number
@typegoose.prop({ default: 0, required: true })
public currentRoomId: number
}
const UserSessionModel = typegoose.getModelForClass(UserSession)