2
0
mirror of https://github.com/thedevs-network/the-guard-bot synced 2025-09-05 00:25:19 +00:00

removed custom command's adding step and make it inline

This commit is contained in:
Pouria Ezzati
2017-11-20 14:32:34 +03:30
parent ff5eca49e7
commit 73833c9740
4 changed files with 49 additions and 48 deletions

View File

@@ -14,8 +14,8 @@ Command.ensureIndex({
const addCommand = command =>
Command.update(
{ id: command.id, isActive: false },
{ id: command.id, isActive: false, state: 'add', },
{ id: command.id },
Object.assign({}, command, { isActive: false }),
{ upsert: true }
);