function tripal_chado_update_7307

3.x tripal_chado.install tripal_chado_update_7307()

Add cvterm mapping for the Publication entity type

File

tripal_chado/tripal_chado.install, line 1018

Code

function tripal_chado_update_7307() {
  try {
    $identifier = array(
      'cv_id' => array('name' => 'tripal_pub'),
      'name' => 'Publication'
    );
    $cvterm = chado_get_cvterm($identifier);
    tripal_chado_add_cvterm_mapping($cvterm->cvterm_id, 'pub', NULL);
  }
  catch (\PDOException $e) {
    $error = $e->getMessage();
    throw new DrupalUpdateException('Could not perform update: ' . $error);
  }
}