On the Backend, we are using Laravel 5.1 because the previous developer decided to use this artifact instead of 5.4, which was available at the time of the project creation. To perform the payments, subscriptions, invoices - we are using Billable(Cashier) with Stripe.
The problem is next one, that we are facing this issue only on the Staging (dev) server, but not on the Local environment:
This is how it was done (sorry for not following PSR. We have no time to refactor, as the client is burning)
public function postJoin(Request $request)
{
$input = $request->all();
try {
$this->user->subscription($input['plan'])
->create($this->user->setOrGetStripeCustomerId(), [
'email' => $this->user->email
]);
$this->user->update(['paid' => true]);
return redirect('subusers')
->with('info', Lang::get('app.membership_active'));
} catch (Exception $e) {
return back()->with('info', $e->getMessage());
}
}
What can cause this issue?
via Chebli Mohamed
Aucun commentaire:
Enregistrer un commentaire