You are here

function gauth_user_update_7001 in Google Auth 7

Same name and namespace in other branches
  1. 7.2 gauth_user/gauth_user.install \gauth_user_update_7001()

Add the gauth_accounts.access_type field.

File

gauth_user/gauth_user.install, line 84
Install and uninstall functions for the Google Auth User module.

Code

function gauth_user_update_7001() {
  $field = array(
    'type' => 'varchar',
    'not null' => TRUE,
    'length' => 255,
    'default' => 'offline',
    'description' => 'Stores the access type of the account.',
  );
  db_add_field('gauth_user_services', 'access_type', $field);
  db_update('gauth_user_services')
    ->fields(array(
    'access_type' => 'offline',
  ))
    ->execute();
}