Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Fixing undefined currency value for contribution notification #14425

Merged
merged 1 commit into from
Jun 14, 2018

Conversation

ryanml
Copy link
Contributor

@ryanml ryanml commented Jun 14, 2018

Fixes: #14417

Basically the transaction keys were swapped, trying to access the currency prop first as opposed to fiat. Contribution map is structured like so:

{ "fiat": Map { "amount": 10, "currency": "BAT" }, "rates": Map { "EUR": 0.16415440004057, "USD": 0.19355117, "BCH": 0.00022834810733109726, "BTC": 0.0000327, "DASH": 0.0007821603506058262, "BTG": 0.005958015042318794, "XRP": 0.36440067259188086, "ETH": 0.0004051167013833253, "LTC": 0.0020486297689414294 }, "satoshis": undefined, "altcurrency": "BAT", "probi": "10000000000000000000", "fee": undefined }

Submitter Checklist:

  • Submitted a ticket for my issue if one did not already exist.
  • Used Github auto-closing keywords in the commit message.
  • Added/updated tests for this change (for new code or code which already has tests).
  • Ran git rebase -i to squash commits (if needed).
  • Tagged reviewers and labelled the pull request as needed.
  • Request a security/privacy review as needed. (Ask a Brave employee to help if you cannot access this document.)

Test Plan:

Defined in #14417

Reviewer Checklist:

  • Request a security/privacy review as needed if one was not already requested.

Tests

  • Adequate test coverage exists to prevent regressions
  • Tests should be independent and work correctly when run individually or as a suite ref
  • New files have MPL2 license header

@ryanml ryanml added this to the 0.23.x (Beta Channel) milestone Jun 14, 2018
@ryanml ryanml self-assigned this Jun 14, 2018
@ryanml ryanml requested a review from jasonrsadler June 14, 2018 21:09
Copy link
Contributor

@jasonrsadler jasonrsadler left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

++ 🥇

@jasonrsadler jasonrsadler merged commit 081069c into brave:master Jun 14, 2018
@bsclifton
Copy link
Member

don't forget to merge this into 0.23.x 😄

@jasonrsadler
Copy link
Contributor

Doing that now!!!!!!!!!! 😄

jasonrsadler pushed a commit that referenced this pull request Jun 14, 2018
Fixing undefined currency value for contribution notification
@jasonrsadler
Copy link
Contributor

master: 081069c
0.23.x: 90f3180

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants