summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJose Antonio Reyero del Prado2011-04-01 18:17:29 (GMT)
committer Jose Antonio Reyero del Prado2011-04-01 18:17:29 (GMT)
commitf43fecd5d70e163857d63a7533baaf4f2eda1e5e (patch)
tree6b098f6e13020551c9e119f05b25ba15238dcc76
parent1ae0e75ebb9f0ef26851c664057adf904b5d0d35 (diff)
Issue #1112016: Warnings when reset vocabulary to alphabetical
-rw-r--r--i18n_taxonomy/i18n_taxonomy.module3
1 files changed, 2 insertions, 1 deletions
diff --git a/i18n_taxonomy/i18n_taxonomy.module b/i18n_taxonomy/i18n_taxonomy.module
index e0a5984..54ba66f 100644
--- a/i18n_taxonomy/i18n_taxonomy.module
+++ b/i18n_taxonomy/i18n_taxonomy.module
@@ -657,7 +657,8 @@ function i18n_taxonomy_form_alter(&$form, $form_state, $form_id) {
break;
case 'taxonomy_overview_terms':
- if (i18n_taxonomy_vocabulary_mode($form['#vocabulary']->vid) & I18N_MODE_TRANSLATE) {
+ // We check for vocabulary object first, because when confirming alphabetical ordering it uses the same form
+ if (!empty($form['#vocabulary']) && i18n_taxonomy_vocabulary_mode($form['#vocabulary']->vid) & I18N_MODE_TRANSLATE) {
foreach (element_children($form) as $key) {
if (isset($form[$key]['#term']) && ($lang = i18n_object_langcode($form[$key]['#term']))) {
$form[$key]['view']['#suffix'] = ' ('. i18n_language_name($lang) .')';