empty($account->picture) will be much more successful.It handles the case that it's unset.