Fix fatal error after the login. Ref #275
Merge pull request #278 from joomla/issue-275

Fix fatal error after the login. Ref #275