I am new to laravel and I got a question here. I am trying to inject 'IlluminateHttpRequest' to my custom Class.
Error: __construct() must be an instance of IlluminateHttpRequest, none given,
What is wrong with my code below? Thanks!
namespace AppLibrary;
use Crypt;
use IlluminateHttpRequest;
class MenuAccess
{
public function __construct(Request $request){
$this->request = $request;
}
public function setLoginSession($user){
$user = Crypt::encrypt($user);
$this->request->session()->put('PAZPOSID', $user);
retu $request->session()->pull('PAZPOSID');
}
}
