How to solve “curl error 3 url malformed” in unicodedeveloper paystack laravel package
Unicodedeveloper created a resourceful and seamless package for us to integrate the paystack payment gateway in our laravel app on github.
The package works just fine on laravel 5.5 and lower but may cause some errors in newer versions of laravel such as the above error. To solve this problem, once you install the package you have to publish the configuration file using
php artisan vendor:publish --provider="Unicodeveloper\Paystack\PaystackServiceProvider"
After publishing, verify if you have paystack.php in your config folder, it must be in this folder or else you have the error.
If you cant find paystack.php file in config folder, then it has been installed elsewhere in your laravel project. Now rerun the publishing command line code again and now the file should be moved into config folder.
Next to do is to clear your app cache using
php artisan config:cache
to clear your configuration cache and
php artisan cache:clear
to clear all of the app’s cache.
Restart your app and there you go!