You are here

function hosting_package_update_4 in Hosting 6.2

Same name and namespace in other branches
  1. 5 package/hosting_package.install \hosting_package_update_4()
  2. 7.4 package/hosting_package.install \hosting_package_update_4()
  3. 7.3 package/hosting_package.install \hosting_package_update_4()

Package languages are associated to package instances, not packages

File

package/hosting_package.install, line 167
Install, update and uninstall for the package management module.

Code

function hosting_package_update_4() {
  include_once drupal_get_path('module', 'hosting_task') . '/hosting_task.module';
  $ret = array();
  $ret[] = update_sql("DROP TABLE {hosting_package_languages}");
  $ret[] = update_sql("CREATE TABLE {hosting_package_languages} (\n    iid int UNSIGNED NOT NULL,\n    language VARCHAR(12) NOT NULL DEFAULT ''\n  )  /*!40100 DEFAULT CHARACTER SET UTF8 */");

  // Re-verify all existing platforms
  $result = db_query("SELECT nid FROM {node} WHERE type='platform' AND status=1");
  while ($platform = db_fetch_object($result)) {
    hosting_add_task($platform->nid, 'verify');
  }
  return $ret;
}