MDL-15042 fixed regression - thanks Howard

This commit is contained in:
skodak 2008-05-29 15:07:05 +00:00
parent f17a34b5ef
commit 7de9dff6c5

View File

@ -5465,7 +5465,7 @@ function role_cap_duplicate($sourcerole, $targetrole) {
$caps = $DB->get_records_sql("SELECT *
FROM {role_capabilities}
WHERE roleid = ? AND contextid = ?",
array($grade_category->id, $systemcontext->id));
array($sourcerole->id, $systemcontext->id));
// adding capabilities
foreach ($caps as $cap) {
unset($cap->id);