Max wrote a nice tutorial on how to work with null objects in Laravel 5.

laravel 5 null objects