? Success

User tests: Successful: Unsuccessful:

avatar mbabker
mbabker
20 Jun 2016

Summary of Changes

ConfigModelComponent::save() dispatches the onExtension(Before|After)Save events passing the JTable object by reference. This is contradictory to how the onXXX(Before|After)Save events are dispatched in JModelAdmin. The references are removed.

Testing Instructions

Events are correctly dispatched and processed when saving an extension record (com_config component, com_modules, and com_plugins as examples).

avatar mbabker mbabker - open - 20 Jun 2016
avatar mbabker mbabker - change - 20 Jun 2016
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 20 Jun 2016
Labels Added: ?
avatar ggppdk ggppdk - test_item - 20 Jun 2016 - Tested successfully
avatar ggppdk
ggppdk - comment - 20 Jun 2016

I have tested this item successfully on 8d78fd3

Tested with my plugin, event methods are called properly,

also it is not only about how events are called in JModelAdmin.
The signatures of the methods do no have the reference:
e.g.

public function onExtensionBeforeSave($context, $table, $isNew)
```<hr /><sub>This comment was created with the <a href="https://github.com/joomla/jissues">J!Tracker Application</a> at <a href="https://issues.joomla.org/tracker/joomla-cms/10878">issues.joomla.org/joomla-cms/10878</a>.</sub>
avatar brianteeman brianteeman - change - 20 Jun 2016
Category Administration Components
avatar mahagr
mahagr - comment - 21 Jun 2016

BTW, reference is used also by MenusModelItem::save() and 17 other places.

Here's regular expression to find out all the instances when table is passed as reference: \$dispatcher->trigger\(.*?&\$table

avatar ghazal ghazal - test_item - 21 Jun 2016 - Tested successfully
avatar ghazal
ghazal - comment - 21 Jun 2016

I have tested this item successfully on 8d78fd3


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

avatar brianteeman brianteeman - change - 21 Jun 2016
Status Pending Ready to Commit
avatar brianteeman
brianteeman - comment - 21 Jun 2016

RTC


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

avatar joomla-cms-bot joomla-cms-bot - change - 21 Jun 2016
Labels Added: ?
avatar roland-d roland-d - change - 16 Jul 2016
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2016-07-16 18:05:02
Closed_By roland-d
avatar roland-d roland-d - close - 16 Jul 2016
avatar roland-d roland-d - merge - 16 Jul 2016
avatar joomla-cms-bot joomla-cms-bot - close - 16 Jul 2016
avatar joomla-cms-bot joomla-cms-bot - change - 16 Jul 2016
Labels Removed: ?

Add a Comment

Login with GitHub to post a comment