From 2d8fb00c927aa48840fff5d8ac4753f54e684f40 Mon Sep 17 00:00:00 2001 From: Travis Eden Date: Tue, 14 Aug 2018 15:42:08 -0400 Subject: [PATCH] implement silent failing on reward claims when user is not reward approved --- src/renderer/redux/actions/rewards.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/renderer/redux/actions/rewards.js b/src/renderer/redux/actions/rewards.js index d98d4a9b66d..18823dcf3f6 100644 --- a/src/renderer/redux/actions/rewards.js +++ b/src/renderer/redux/actions/rewards.js @@ -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; }