I use scrutinizer to analyze my code. And almost everything is fixed, but I can not solve this problem.
Accessing id on the interface Illuminate\Contracts\Auth\Authenticatable suggest that you code against a concrete implementation. How about adding an instanceof check?
I see the problem because it is an interface that does not exist, but my code works fine. So, how can I pass this code when parsing the code?
thank
Edit
An error was received on these lines (and some other files are almost the same)
$this->tracert->log(
'users',
$this->auth->user()->id,
$this->auth->user()->id,
'Login'
);
Constructor of this class
public function __construct(Guard $auth, Tracert $tracert)
{
parent::__construct($auth);
$this->tracert = $tracert;
}
constructor of my base controller:
public function __construct(Guard $auth)
{
$this->auth = $auth;
$this->config = objectify(config('blogify'));
$this->auth_user = $this->auth->check() ? $this->auth->user() : false;
}
Used contract https://github.com/illuminate/contracts/blob/master/Auth/Guard.php
source
share