wikijs-fork/models/bruteforce.js
2016-11-20 20:09:50 -05:00

18 lines
349 B
JavaScript

"use strict";
/**
* BruteForce schema
*
* @type {<Mongoose.Schema>}
*/
var bruteForceSchema = Mongoose.Schema({
_id: { type: String, index: 1 },
data: {
count: Number,
lastRequest: Date,
firstRequest: Date
},
expires: { type: Date, index: { expires: '1d' } }
});
module.exports = Mongoose.model('Bruteforce', bruteForceSchema);