You are here

akamai.install in Akamai 7.2

File

akamai.install
View source
<?php

/**
 * Update hook for upgrading to Drupal 7.
 */
function akamai_update_7000() {
  db_update('variable')
    ->fields(array(
    'name' => 'akamai_basepath',
  ))
    ->condition('name', 'AkamaiCC_basepath')
    ->execute();
  db_update('variable')
    ->fields(array(
    'name' => 'akamai_username',
  ))
    ->condition('name', 'AkamaiCC_name')
    ->execute();
  db_update('variable')
    ->fields(array(
    'name' => 'akamai_password',
  ))
    ->condition('name', 'AkamaiCC_pwd')
    ->execute();
  db_update('variable')
    ->fields(array(
    'name' => 'akamai_action',
  ))
    ->condition('name', 'AkamaiCC_action')
    ->execute();
  db_update('variable')
    ->fields(array(
    'name' => 'akamai_domain',
  ))
    ->condition('name', 'AkamaiCC_domain')
    ->execute();
  db_update('variable')
    ->fields(array(
    'name' => 'akamai_wsdl',
  ))
    ->condition('name', 'AkamaiCC_soap_wsdl')
    ->execute();
  db_update('variable')
    ->fields(array(
    'name' => 'akamai_email',
  ))
    ->condition('name', 'AkamaiCC_email')
    ->execute();
}

/**
 * Update hook for upgrading to Drupal 7.x-2.x branch.
 *
 * Remove unneeded variables.
 */
function akamai_update_7001() {
  variable_del('akamai_wsdl');
  variable_del('akamai_restapi_default');
}

/**
 * Remove the email variable not supported in latest API.
 */
function akamai_update_7002() {
  variable_del('akamai_email');
}

/**
 * Implements hook_uninstall().
 */
function akamai_uninstall() {
  variable_del('akamai_action');
  variable_del('akamai_basepath');
  variable_del('akamai_domain');
  variable_del('akamai_password');
  variable_del('akamai_restapi');
  variable_del('akamai_timeout');
  variable_del('akamai_username');
  variable_del('akamai_disabled');
}

Functions

Namesort descending Description
akamai_uninstall Implements hook_uninstall().
akamai_update_7000 Update hook for upgrading to Drupal 7.
akamai_update_7001 Update hook for upgrading to Drupal 7.x-2.x branch.
akamai_update_7002 Remove the email variable not supported in latest API.