mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-02-05 21:33:40 +08:00
11 lines
No EOL
342 B
JavaScript
11 lines
No EOL
342 B
JavaScript
const MonkeyError = require("../handlers/error");
|
|
const { mongoDB } = require("../init/mongodb");
|
|
class BotDAO {
|
|
static async addCommand(command, arguments) {
|
|
return await mongoDB()
|
|
.collection("bot-commands")
|
|
.insertOne({ command, arguments, executed: false, requestTimestamp: Date.now() });
|
|
}
|
|
}
|
|
|
|
module.exports = BotDAO; |