Просмотр исходного кода

Should not require a description for table fields in chado_node_gerneate_tokens

Stephen Ficklin 9 лет назад
Родитель
Сommit
6893992f63
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      tripal_core/api/tripal_core.chado_nodes.title_and_path.inc

+ 1 - 1
tripal_core/api/tripal_core.chado_nodes.title_and_path.inc

@@ -1261,7 +1261,7 @@ function chado_node_generate_tokens($base_table, $token_prefix = FALSE, $locatio
       'location' => $location
     );
 
-    if (preg_match('/TODO/',$field_details['description'])) {
+    if (!array_key_exists('description', $field_details) or preg_match('/TODO/',$field_details['description'])) {
       $tokens[$token]['description'] = 'The '.$field_name.' field of the '.$base_table.' table.';
     }
   }