Permalink
Browse files

MDL-12180, blocks capabilities not appearing when overriding block roles

  • Loading branch information...
1 parent dcc09c5 commit 894722ed9c54f7732f72ad2023bcaa5e1ee84137 toyomoyo committed Nov 15, 2007
Showing with 2 additions and 2 deletions.
  1. +2 −2 lib/accesslib.php
View
@@ -2874,8 +2874,8 @@ function fetch_context_capabilities($context) {
$cb = get_record('block_instance', 'id', $context->instanceid);
$block = get_record('block', 'id', $cb->blockid);
- $SQL = "select * from {$CFG->prefix}capabilities where contextlevel = ".CONTEXT_BLOCK."
- and component = 'block/$block->name'";
+ $SQL = "select * from {$CFG->prefix}capabilities where (contextlevel = ".CONTEXT_BLOCK." AND component = 'moodle')
+ OR (component = 'block/$block->name')";
break;
default:

0 comments on commit 894722e

Please sign in to comment.