Minor Update to Remove PHP Notice

Eliminates the “Notice: Trying to get property of non-object” that
might show up in error logs in certain development or production
environments.