MDL-22646 create_context() is internal implementation function, to be used only inside accesslib.php

This commit is contained in:
Petr Skoda 2010-06-04 07:30:42 +00:00
parent 67485c7f3e
commit a07600473d
2 changed files with 4 additions and 4 deletions

View File

@ -1865,13 +1865,13 @@ function is_safe_capability($capability) {
**********************************/
/**
* Create a new context record for use by all roles-related stuff
* Context creation - internal implementation.
*
* Create a new context record for use by all roles-related stuff
* assumes that the caller has done the homework.
*
* @global object
* @global object
* DO NOT CALL THIS DIRECTLY, instead use {@link get_context_instance}!
*
* @param int $contextlevel
* @param int $instanceid
* @param int $strictness

View File

@ -48,7 +48,7 @@ function user_create_user($user) {
$newuserid = $DB->insert_record('user', $user);
/// create USER context for this user
create_context(CONTEXT_USER, $newuserid);
get_context_instance(CONTEXT_USER, $newuserid);
return $newuserid;