aboutsummaryrefslogtreecommitdiff
path: root/engine/classes/ElggPlugin.php
diff options
context:
space:
mode:
authorCash Costello <cash.costello@gmail.com>2011-07-06 07:51:51 -0400
committerCash Costello <cash.costello@gmail.com>2011-07-06 07:51:51 -0400
commitb4f9682d2dae28db4ee183909be3ae439be2a858 (patch)
treea7d98cbd977e63df185a72fa539948820fa630ad /engine/classes/ElggPlugin.php
parent105abf94e68860d1d1d06ef6865d21c65f8a4dde (diff)
downloadelgg-b4f9682d2dae28db4ee183909be3ae439be2a858.tar.gz
elgg-b4f9682d2dae28db4ee183909be3ae439be2a858.tar.bz2
Fixes #2204 standardized the hooks/overrides for plugin settings and usersettings
Diffstat (limited to 'engine/classes/ElggPlugin.php')
-rw-r--r--engine/classes/ElggPlugin.php13
1 files changed, 7 insertions, 6 deletions
diff --git a/engine/classes/ElggPlugin.php b/engine/classes/ElggPlugin.php
index e46ac4273..d837431fc 100644
--- a/engine/classes/ElggPlugin.php
+++ b/engine/classes/ElggPlugin.php
@@ -315,9 +315,9 @@ class ElggPlugin extends ElggObject {
return false;
}
// Hook to validate setting
- $value = elgg_trigger_plugin_hook('plugin:setting', 'plugin', array(
- 'plugin' => $this->pluginID,
- 'plugin_object' => $this,
+ $value = elgg_trigger_plugin_hook('setting', 'plugin', array(
+ 'plugin_id' => $this->pluginID,
+ 'plugin' => $this,
'name' => $name,
'value' => $value
), $value);
@@ -454,10 +454,11 @@ class ElggPlugin extends ElggObject {
}
// Hook to validate setting
- // note this doesn't pass the namespaced name!
- $value = elgg_trigger_plugin_hook('plugin:usersetting', 'user', array(
+ // note: this doesn't pass the namespaced name
+ $value = elgg_trigger_plugin_hook('usersetting', 'plugin', array(
'user' => $user,
- 'plugin' => $this->getID(),
+ 'plugin' => $this,
+ 'plugin_id' => $this->getID(),
'name' => $name,
'value' => $value
), $value);