[feature/events] Correct core.acp_profile_edit event

Still used the "old" way.

PHPBB3-9550
This commit is contained in:
Erik Frèrejean 2012-04-10 22:19:18 +02:00 committed by Joas Schilling
parent b04141b14f
commit 05c0d1ad17

View file

@ -27,9 +27,10 @@ class acp_profile
function main($id, $mode) function main($id, $mode)
{ {
global $config, $db, $user, $auth, $template, $cache, $phpbb_dispatcher; global $config, $db, $user, $auth, $template, $cache;
global $phpbb_root_path, $phpbb_admin_path, $phpEx, $table_prefix; global $phpbb_root_path, $phpbb_admin_path, $phpEx, $table_prefix;
global $request; global $request;
global $phpbb_dispatcher;
include($phpbb_root_path . 'includes/functions_posting.' . $phpEx); include($phpbb_root_path . 'includes/functions_posting.' . $phpEx);
include($phpbb_root_path . 'includes/functions_user.' . $phpEx); include($phpbb_root_path . 'includes/functions_user.' . $phpEx);
@ -876,10 +877,8 @@ class acp_profile
} }
} }
$vars = array('field_row', 'visibility_ary', 'exclude'); $vars = array('field_row', 'visibility_ary', 'exclude');
$event = new phpbb_event_data(compact($vars)); extract($phpbb_dispatcher->trigger_event('core.acp_profile_edit', compact($vars)));
$phpbb_dispatcher->dispatch('core.acp_profile_edit', $event);
extract($event->get_data_filtered($vars));
break; break;
} }