function _subscriptions_mail_extend_mail_edit in Subscriptions 2.0.x
Same name and namespace in other branches
- 7 subscriptions_mail.install \_subscriptions_mail_extend_mail_edit()
Adds a column to the {mail_edit} table.
3 calls to _subscriptions_mail_extend_mail_edit()
- subscriptions_mail_install in subscriptions_mail/
subscriptions_mail.install - Implements hook_install().
- subscriptions_mail_modules_installed in subscriptions_mail/
subscriptions_mail.module - Implements hook_modules_installed().
- subscriptions_mail_update_7000 in subscriptions_mail/
subscriptions_mail.install - Database update function 7000: Extend the {mail_edit} table.
File
- subscriptions_mail/
subscriptions_mail.install, line 21 - Subscriptions Mail module installation.
Code
function _subscriptions_mail_extend_mail_edit() {
if (!function_exists('subscriptions_mail_schema_alter')) {
$t = get_t();
throw new DrupalUpdateException($t('@Subscriptions_Mail must be enabled before it can be updated', array(
'@Subscriptions_Mail' => 'Subscriptions Mail',
)) . ' - ');
}
$new_schema = array();
subscriptions_mail_schema_alter($new_schema);
foreach ($new_schema['mail_edit']['fields'] as $name => $spec) {
db_add_field('mail_edit', $name, $spec);
}
}