From 39b6fdccc4d628d7aa8427b52c340316a4ecbe7b Mon Sep 17 00:00:00 2001 From: schneefux Date: Mon, 3 Apr 2017 16:04:46 +0200 Subject: send data type notification to processor --- worker.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/worker.js b/worker.js index 44e85c5..adf415c 100644 --- a/worker.js +++ b/worker.js @@ -42,8 +42,9 @@ if (MADGLORY_TOKEN == undefined) throw "Need an API token"; matches = jsonapi.parse(data); // send match structure await Promise.all(matches - .map(async (match) => await ch.sendToQueue("process", - new Buffer(JSON.stringify(match)), { persistent: true }) + .map((match) => ch.sendToQueue("process", + new Buffer(JSON.stringify(match)), + { persistent: true, type: "match" }) )); if (matches.length < 50) exhausted = true; } catch (err) { -- cgit v1.3.1