1 comment.install comment_update_1000()

Renames {comment}.language to {comment}.langcode.

Related topics

File

core/modules/comment/comment.install, line 332
Install, update and uninstall functions for the Comment module.

Code

function comment_update_1000() {
  db_drop_index('comment', 'comment_nid_langcode');
  $langcode_spec = array(
    'type' => 'varchar',
    'length' => 12,
    'not null' => TRUE,
    'default' => '',
    'description' => "Language code, e.g. 'de' or 'en-US'.",
  );
  db_change_field('comment', 'language', 'langcode', $langcode_spec);
  db_add_index('comment', 'comment_nid_langcode', array('nid', 'langcode'));
}