summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorschneefux <schneefux+commit@schneefux.xyz>2017-08-21 19:49:42 +0200
committerschneefux <schneefux+commit@schneefux.xyz>2017-08-21 19:49:42 +0200
commit670d4df1194412e2e5c85aa4d955aa5dd6b975cf (patch)
treea1c76535a4431756b9ba52739d76a5a60b059fdd
parent3346d1635e1b261648e90bae0146f70c4c60a634 (diff)
downloadprocessor-670d4df1194412e2e5c85aa4d955aa5dd6b975cf.tar.gz
processor-670d4df1194412e2e5c85aa4d955aa5dd6b975cf.zip
remove match_update hotfix, send match_invalid
-rw-r--r--worker.js7
1 files changed, 3 insertions, 4 deletions
diff --git a/worker.js b/worker.js
index 764e1d8..4bf1cdc 100644
--- a/worker.js
+++ b/worker.js
@@ -185,14 +185,13 @@ amqp.connect(RABBITMQ_URI).then(async (rabbit) => {
await ch.publish("amq.topic",
msg.properties.headers.notify + "." + match.id,
new Buffer("match_dupe"));
- // HOTFIX TODO remove me, web should listen to match_dupe
- await ch.publish("amq.topic",
- msg.properties.headers.notify,
- new Buffer("match_update"));
}
await ch.nack(msg, false, false);
} else if (match.rosters.length < 2 || match.rosters[0].id == "null") {
logger.info("invalid match", match.id);
+ await ch.publish("amq.topic",
+ msg.properties.headers.notify + "." + match.id,
+ new Buffer("match_invalid"));
// it is really `"null"`.
// reject invalid matches (handling API bugs)
await ch.nack(msg, false, false);