? Success

User tests: Successful: Unsuccessful:

avatar addondev
addondev
6 Sep 2016

Summary of Changes

Sometimes, when a page does not exist, we can see an error Call to a member function getType() on null. The PR is a fix.

avatar addondev addondev - open - 6 Sep 2016
avatar addondev addondev - change - 6 Sep 2016
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 6 Sep 2016
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - change - 6 Sep 2016
Category Plugins Front End
avatar andrepereiradasilva
andrepereiradasilva - comment - 6 Sep 2016

can you make clear instructions on how to reproduce the issue
And also add the test instructions.

avatar addondev
addondev - comment - 6 Sep 2016

@andrepereiradasilva,
I tested some extensions for custom error pages, such as sh404SEF and got such an error. After I applied the patch, it works without any issue. I know, I should have written to the developer, but I think, it is a bug in the core. Basically, the document should be gotten with a method JFactory::getDocument() instead of a method JApplicationWeb->getDocument().

avatar andrepereiradasilva
andrepereiradasilva - comment - 6 Sep 2016

I don't see any issue in the core error pages.
@mbabker can you please check this.

avatar mbabker
mbabker - comment - 6 Sep 2016

Seems like something is breaking the application then because at least with JApplicationSite::dispatch() it is loading the JDocument object into the application's variable THEN assigning it to JFactory::$document. These events are dispatched well after that assignment happens. I personally do not consider this a valid fix; it's working around something else breaking things.

avatar andrepereiradasilva
andrepereiradasilva - comment - 6 Sep 2016

thanks for explaining michael

avatar brianteeman
brianteeman - comment - 9 Oct 2016

Closed as not a core issue


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/11948.

avatar brianteeman brianteeman - change - 9 Oct 2016
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2016-10-09 11:24:15
Closed_By brianteeman
avatar brianteeman brianteeman - close - 9 Oct 2016

Add a Comment

Login with GitHub to post a comment