back/app/models/coin_reward.rb
# See the comment in CoinRewardsController#mint about the way the referral
# mechanism should work when we have external social apps, with a minting quota.
See the comment in CoinRewardsController#mint about the way the referral
mechanism should work when we have external social apps, with a minting quota.
See the comment in CoinRewardsController#mint about the way the referral mechanism should work when we have external social apps with a minting quota .
def validate_referral_converted
    return unless referral.present?
    errors.add(:referral, "is not converted, therefore doesn't deserve a reward") unless referral.converted?
  end
def validate_referral_converted return unless referral . present? errors . add ( :referral , "is not converted, therefore doesn't deserve a reward" ) unless referral . converted? end
See the comment in CoinRewardsController#mint about the way the referral
mechanism should work when we have external social apps, with a minting quota.
See the comment in CoinRewardsController#mint about the way the referral mechanism should work when we have external social apps with a minting quota .
# Skip if referral is absent, let another validation take care of it: