You are here

function _fboauth_change_user_mail_field in Facebook OAuth (FBOAuth) 7

Same name and namespace in other branches
  1. 6 fboauth.install \_fboauth_change_user_mail_field()
  2. 7.2 fboauth.install \_fboauth_change_user_mail_field()

Extend maximum email length to 320 chars

Parameters

$action: Optional. May be specified as "install" to adjust the column length to the longer limit or "uninstall" to adjust the column to the default length.

1 call to _fboauth_change_user_mail_field()
fboauth_install in ./fboauth.install
Implements hook_install().

File

./fboauth.install, line 75
Provides install and update functions for the Facebook OAuth module.

Code

function _fboauth_change_user_mail_field($action = 'install') {
  $res = array();
  $schema = array(
    'users' => drupal_get_schema('users'),
  );
  if ($action == 'install') {
    fboauth_schema_alter($schema);
  }
  db_change_field('users', 'mail', 'mail', $schema['users']['fields']['mail']);
  return $res;
}