Fixed or logic break (#8857)

This commit is contained in:
Keith Holliday
2017-07-10 21:08:35 -06:00
committed by GitHub
parent 045378b820
commit 3aa7b4b631
@@ -22,7 +22,7 @@ function($rootScope, User, $http, Content, Notification) {
};
Payments.checkGemAmount = function(data) {
if(data.gift.type === "gems" && !data.gift.gems.amount || data.gift.gems.amount === 0) {
if (data.gift.type === "gems" && (!data.gift.gems.amount || data.gift.gems.amount === 0)) {
Notification.error(window.env.t('badAmountOfGemsToPurchase'), true);
return false;
}