You are here

function moopapi_enable in Module Object Oriented Programming API 7

Same name and namespace in other branches
  1. 6.2 moopapi.install \moopapi_enable()
  2. 6 moopapi.install \moopapi_enable()
  3. 7.2 moopapi.install \moopapi_enable()

@file Install, update and uninstall functions for the Moopapi module.

File

./moopapi.install, line 8
Install, update and uninstall functions for the Moopapi module.

Code

function moopapi_enable() {

  // @todo Abstract it.

  //db_query('UPDATE {system} s SET weight = -1000 WHERE name = "moopapi"');
  db_update('system')
    ->fields(array(
    'weight' => 1,
  ))
    ->condition('type', 'module')
    ->condition('name', 'moopapi')
    ->execute();
}