You are here

function og_test_module_implements_alter in Organic groups 8

Same name and namespace in other branches
  1. 7.2 tests/og_test.module \og_test_module_implements_alter()

Implements hook_module_implements_alter().

File

tests/modules/og_test/og_test.module, line 20

Code

function og_test_module_implements_alter(&$implementations, $hook) {
  if ($hook == 'entity_insert') {

    // Move our implementation of hook_entity_insert() to the top of the list so
    // that it will run before og_entity_insert().
    $implementation = $implementations['og_test'];
    unset($implementations['og_test']);
    $implementations = [
      'og_test' => $implementation,
    ] + $implementations;
  }
}