4👍
✅
I think you write the constructor of your event class wrong.
Here you put extra $
before message
and user
variable
public function __construct($message, User $user)
{
$this->$message = $message;
$this->$user = $user;
}
It should be like following one.
public function __construct($message, User $user)
{
$this->message = $message;
$this->user = $user;
}
Source:stackexchange.com