You are here

function hook_mongodb_block_info_alter in MongoDB 7

Alters the information collected in hook_block_info.

The core hook_block_info_alter is run-time, not supported. This is build time.

Parameters

array $blocks: Associative array, key is the module name, value is the hook_block_info returned by the module. As Drupal core and contrib rarely sets status and region this hook should be used to enable those.

2 functions implement hook_mongodb_block_info_alter()

Note: this list is generated by pattern matching, so it may include some functions that are not actually implementations of this hook.

mongodb_block_mongodb_block_info_alter in mongodb_block/mongodb_block.module
Implements hook_mongodb_block_info_alter().
mongodb_block_ui_mongodb_block_info_alter in mongodb_block_ui/mongodb_block_ui.module
Implements hook_mongodb_block_info_alter().
1 invocation of hook_mongodb_block_info_alter()
_mongodb_block_rehash in mongodb_block/mongodb_block.module
Updates the block collection with the blocks currently exported by modules.

File

mongodb_block/mongodb_block.api.php, line 84
Hooks provided by the Block module.

Code

function hook_mongodb_block_info_alter(array &$blocks) {

  // Enable the management block.
  $blocks['system']['management']['status'] = 1;
  $blocks['system']['management']['region'] = 'sidebar_first';
}