Improvements for timing of Postmark webhooks
This commit is contained in:
parent
5e5dc3eb65
commit
eb1475a451
|
|
@ -65,7 +65,7 @@ class PostMarkController extends BaseController
|
|||
public function webhook(Request $request)
|
||||
{
|
||||
if ($request->header('X-API-SECURITY') && $request->header('X-API-SECURITY') == config('services.postmark.token')) {
|
||||
ProcessPostmarkWebhook::dispatch($request->all())->delay(rand(6, 14));
|
||||
ProcessPostmarkWebhook::dispatch($request->all())->delay(15);
|
||||
|
||||
return response()->json(['message' => 'Success'], 200);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -77,7 +77,7 @@ class AutoBill implements ShouldQueue
|
|||
nlog($e->getMessage());
|
||||
}
|
||||
|
||||
nlog("Firing email for invoice {$invoice->number}");
|
||||
nlog("Firing email for invoice {$invoice->number} which failed to capture payment");
|
||||
}
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -119,10 +119,6 @@ class AutoBillInvoice extends AbstractService
|
|||
/* $gateway fee */
|
||||
$this->invoice = $this->invoice->service()->addGatewayFee($gateway_token->gateway, $gateway_token->gateway_type_id, $amount)->save();
|
||||
|
||||
|
||||
nlog($this->invoice->amount);
|
||||
nlog($this->invoice->balance);
|
||||
|
||||
//change from $this->invoice->amount to $this->invoice->balance
|
||||
if ($is_partial) {
|
||||
$fee = $this->invoice->balance - $invoice_total;
|
||||
|
|
|
|||
Loading…
Reference in New Issue