Call to undefined function Illuminate\Events\array_wrap() in Laravel

Categorized as Laravel Tagged

If you catch this error, you should check your Laravel version. Since the version 8, you have to use another helper:

use Illuminate\Support\Arr;
 
$string = 'Laravel 9';
 
$array = Arr::wrap($string); 

Leave a reply

Your email address will not be published.