You are here

function user_badges_update_6001 in User Badges 6

Same name and namespace in other branches
  1. 6.2 user_badges.install \user_badges_update_6001()
  2. 7 user_badges.install \user_badges_update_6001()
  3. 7.2 user_badges.install \user_badges_update_6001()
  4. 7.3 user_badges.install \user_badges_update_6001()

Implements hook_update_N() new DB structure

File

./user_badges.install, line 196
@brief User Badges install file

Code

function user_badges_update_6001() {
  $ret = array();
  db_drop_primary_key($ret, 'user_badges_user');
  db_add_primary_key($ret, 'user_badges_user', array(
    'bid',
    'uid',
    'type',
  ));
  db_add_index($ret, 'user_badges_user', 'type', array(
    'type',
  ));
  return $ret;
}