You are here

function invite_update_7 in Invite 5

Same name and namespace in other branches
  1. 5.2 invite.install \invite_update_7()
  2. 6.2 invite.install \invite_update_7()
  3. 7.2 invite.install \invite_update_7()

Switch to token.module.

File

./invite.install, line 212

Code

function invite_update_7() {
  $ret = array();
  $old = array(
    '@site',
    '@join_link',
    '@homepage',
    '@message',
    '@inviter',
  );
  $new = array(
    '[site-name]',
    '[join-link]',
    '[site-url]',
    '[invite-message]',
    '[inviter]',
  );
  _invite_update_tokens('invite_default_mail_template', $old, $new);
  $ret[] = array(
    'query' => 'The message tokens for the invite module have been successfully updated.',
    'success' => TRUE,
  );
  drupal_set_message(strtr('Please note that invite now depends on the %token module.', array(
    '%token' => l('token', 'http://drupal.org/project/token', array(
      'target' => '_blank',
    ), NULL, NULL, TRUE),
  )), 'error');
  return $ret;
}