Skip to content
Advertisement

Trying to access array offset on value of type null in laravel

I am getting this error when I am trying to create a new object

$provider = new ExpressCheckout;
$response = $provider->setExpressCheckout($checkoutData);

I am using this package https://github.com/srmklive/laravel-paypal to integrate the PayPal ExpressCheckout in my Laravel app

Error Message

ErrorException Trying to access array offset on value of type null

Advertisement

Answer

You should clear the cache. Run these commands

composer update 

php artisan cache:clear 
php artisan config:clear 
php artisan view:clear
User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement