I have searched and found various results like these: auth()->user() is null in Laravel 5.2 and Auth::user() returns null
But, mine is still not working.
I have a similar problem with Laravel 5.2, Try to change Auth::user()->id to Auth::id()
public function scopeOwned($query) { $query->where('user_id', '=', Auth::id()); }
It's worked for me!