@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Never generate $0.00 invoices

Summary: Ref T7769. It might possibly make sense to generate these some day, but for now they aren't payable and we have no use for them.

Test Plan:
- Generated $0.00 invoices, saw code decline to invoice.
- Generated a $7.99 invoice, got an invoice.

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T7769

Differential Revision: https://secure.phabricator.com/D12878

+7 -4
+7 -4
src/applications/phortune/worker/PhortuneSubscriptionWorker.php
··· 15 15 return; 16 16 } 17 17 18 + $currency = $subscription->getCostForBillingPeriodAsCurrency( 19 + $last_epoch, 20 + $next_epoch); 21 + if (!$currency->isPositive()) { 22 + return; 23 + } 24 + 18 25 $account = $subscription->getAccount(); 19 26 $merchant = $subscription->getMerchant(); 20 27 ··· 47 54 $cart = $account->newCart($actor, $cart_implementation, $merchant); 48 55 49 56 $purchase = $cart->newPurchase($actor, $product); 50 - 51 - $currency = $subscription->getCostForBillingPeriodAsCurrency( 52 - $last_epoch, 53 - $next_epoch); 54 57 55 58 $purchase 56 59 ->setBasePriceAsCurrency($currency)