diff --git a/README.md b/README.md index e98d9db..f4ad8ec 100644 --- a/README.md +++ b/README.md @@ -181,7 +181,11 @@ class PaymentController extends Controller */ public function redirectToGateway() { - return Paystack::getAuthorizationUrl()->redirectNow(); + try{ + return Paystack::getAuthorizationUrl()->redirectNow(); + }catch(\Exception $e) { + return Redirect::back()->withMessage(['msg'=>'The paystack token has expired. Please refresh the page and try again.', 'type'=>'error']); + } } /**