I was using arrays to pass data back to a view from a controller, but now have switched to using just strings, however this error pops up.
" array_merge(): Argument #2 is not an array "
I'm not even using an array anymore, and i've done php artisan clear:cache incase there was some cache I didn't know about. I'm new to laravel but all the results I find are dealing with people incorrectly using arrays, whereas i'm just passing a simple string.
Can somebody please help? Below is my code
section of code in controller
else {
$result = 'That email belongs to an existing referrer.';
return view('admin.invalidReferrer', $result);
section of code in invalidReferrer.blade.php @extends('admin.admin')
@section('results')
<h4>{{ $result }}</h4>
@stop
previous controller solution
else {
$result = ['That email belongs to an existing referrer.'];
return view('admin.invalidReferrer', compact('result'));
previous blade solution
@section('results')
<h4>{{ $result[0] }}</h4>
@stop