Trying to get property 'id' of non-object

Posted 1 month ago by muazzamazaz

In the following code, I'm getting error;

use Auth;

----
---

public function __construct()
    {
        $this->currentuser = Auth::user()->id;
    }

Please sign in or create an account to participate in this conversation.

Reply to

Use Markdown with GitHub-flavored code blocks.