From 944f994742edcbccfd20232e2a0a88b38e4e6a28 Mon Sep 17 00:00:00 2001 From: schneefux Date: Sat, 8 Apr 2017 18:19:01 +0200 Subject: push winner to roster --- worker.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/worker.js b/worker.js index 6565884..558f3ed 100644 --- a/worker.js +++ b/worker.js @@ -138,6 +138,8 @@ var RABBITMQ_URI = process.env.RABBITMQ_URI, roster.matchApiId = match.id; roster.attributes.shardId = match.attributes.shardId; roster.createdAt = match.createdAt; + // TODO API workaround: roster does not have `winner` + roster.attributes.stats.winner = roster.participants[0].stats.winner; roster.participants = roster.participants.map((participant) => { participant.attributes.shardId = roster.attributes.shardId; -- cgit v1.3.1