You are here

function spaces_context_load_alter in Spaces 6.3

Same name and namespace in other branches
  1. 7.3 spaces.overrides.inc \spaces_context_load_alter()
  2. 7 spaces.overrides.inc \spaces_context_load_alter()

Implementation of hook_context_load_alter().

File

./spaces.overrides.inc, line 6

Code

function spaces_context_load_alter(&$context) {
  $space = spaces_get_space();
  if ($space) {
    foreach (array_keys(context_reactions()) as $plugin) {
      $override = $space->controllers->context
        ->get("{$context->name}:reaction:{$plugin}");
      if (!is_null($override)) {
        $context->reactions[$plugin] = $override;
      }
    }
  }
}