cr-database/models/Stat.ts

14 lines
302 B
TypeScript
Raw Normal View History

2021-12-25 13:37:42 -05:00
import { Document, Schema, model } from 'mongoose';
export interface StatInterface extends Document {
name: 'messages' | 'commands' | 'pages' | 'requests',
value: number,
}
const Stat: Schema = new Schema({
name: String,
value: Number,
});
export default model<StatInterface>('Stat', Stat);