User tests: Successful: Unsuccessful:
This patch fix an initial call of Joomla.loadOptions() when page do not contain the Script options, which could lead to JavaScript error.
Use latest staging,
Add in to index.php of Isis template:
JHtml::_('behavior.core');
$this->addScriptDeclaration('
try{Joomla.getOptions("blabla");alert("Works!");}catch(e){alert("Error!");};
');
And open "Control panel" page.
You see alert "Works!"
You see alert "Error!"
none
Status | New | ⇒ | Pending |
Category | ⇒ | JavaScript |
seems the error is here https://github.com/joomla/joomla-cms/blob/staging/media/system/js/core-uncompressed.js#L159
core.js?9398acd…:1 Uncaught TypeError: Cannot read property 'system.keepalive' of null at Object.Joomla.getOptions (core.js?9398acd…:1) at HTMLDocument.<anonymous> (keepalive.js?9398acd…:1) Joomla.getOptions @ core.js?9398acd…:1 (anonymous) @ keepalive.js?9398acd…:1
What happens if you do console.log (key);
on the line you linked to in the comment above?
console.log(key);
console.log(Joomla.optionsStorage);
results in
system.keepalive
null
Labels |
Added:
?
|
I found the problem,
should be good now
I have tested this item
I have tested this item
Status | Pending | ⇒ | Ready to Commit |
RTC after two successful tests.
Status | Ready to Commit | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2017-06-08 21:06:30 |
Closed_By | ⇒ | wilsonge | |
Labels |
Added:
?
|
I have tested this item✅ successfully on 61b334a
works as described
This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/16488.