[feature/add_events] Event to modify the data array for when a user is added

PHPBB3-9550
This commit is contained in:
David King 2012-08-21 17:04:16 -04:00
parent 0358db2184
commit 4f6f0c0897

View file

@ -255,6 +255,16 @@ function user_add($user_row, $cp_data = false)
}
}
/**
* Use this event to modify the values to be inserted when a user is added
*
* @event core.user_add_modify_data
* @var array sql_ary Array of data to be inserted when a user is added
* @since 3.1-A1
*/
$vars = array('sql_ary');
extract($phpbb_dispatcher->trigger_event('core.user_add_modify_data', compact($vars)));
$sql = 'INSERT INTO ' . USERS_TABLE . ' ' . $db->sql_build_array('INSERT', $sql_ary);
$db->sql_query($sql);