Skip to content

Commit

Permalink
implement silent failing on reward claims when user is not reward app…
Browse files Browse the repository at this point in the history
…roved
  • Loading branch information
daovist committed Aug 14, 2018
1 parent b312edc commit 2d8fb00
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/renderer/redux/actions/rewards.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,11 +40,13 @@ export function doClaimRewardType(rewardType, options) {
}

if (!userIsRewardApproved && rewardType !== rewards.TYPE_CONFIRM_EMAIL) {
const action = doNotify({
id: MODALS.REWARD_APPROVAL_REQUIRED,
isError: false,
});
dispatch(action);
if (!options || !options.failSilently) {
const action = doNotify({
id: MODALS.REWARD_APPROVAL_REQUIRED,
isError: false,
});
dispatch(action);
}

return;
}
Expand Down

0 comments on commit 2d8fb00

Please sign in to comment.