Skip to content

Commit

Permalink
Merge branch 'add-new-modules' of github.com:Muzikie/streamer into ad…
Browse files Browse the repository at this point in the history
…d-new-modules
  • Loading branch information
reyraa committed Nov 15, 2023
2 parents 1ac62e4 + e74460a commit fb1ffc1
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ const applyTransaction = async (blockHeader, tx, events, dbTrx) => {
await BluebirdPromise.map(
anchorVotedData.updatedWinners,
async (winner, index) => {
const { anchorID: winningAnchorID, awardedTo } = winner;
const { anchorID: winningAnchorID, awardedTo, prize } = winner;
const [badge] = await badgesTable.find(
{ awardDate: anchor.createdAt, rank: index + 1 },
['badgeID', 'anchorID', 'awardedTo', 'type', 'awardDate', 'rank', 'prize', 'claimed'],
Expand All @@ -90,6 +90,7 @@ const applyTransaction = async (blockHeader, tx, events, dbTrx) => {

badge.anchorID = winningAnchorID;
badge.awardedTo = awardedTo;
badge.prize = prize;

await badgesTable.upsert(badge, dbTrx);
},
Expand Down

0 comments on commit fb1ffc1

Please sign in to comment.