From 5569b574bffc675d11fa5c2365c7a7e1b53fb57c Mon Sep 17 00:00:00 2001 From: Yaman Qalieh Date: Wed, 26 Oct 2016 22:02:29 -0400 Subject: [PATCH] createWork optimizations --- hourglass/server/main.js | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/hourglass/server/main.js b/hourglass/server/main.js index 3fbadee..48fb2f9 100644 --- a/hourglass/server/main.js +++ b/hourglass/server/main.js @@ -455,13 +455,8 @@ Meteor.methods({ }); var security = securityCheck([[[8, 9, true], 16, false], 10, 20, 11, 12, true], Object.assign(found || {}, input, {userId: Meteor.userId()})); - console.log(security); if (!security) { - input.confirmations = [Meteor.userId()]; - input.reports = []; - input.done = []; - input.numberdone = 0; - input.comments = []; + input = Object.assign(input, {confirmations: [Meteor.userId()], reports: [], done: [], numberdone: 0, comments: []}); work.insert(input); } else { throw new Meteor.Error(errors[security]);