Calling i18n_taxonomy_translate_terms() with a term that is not translated yet (i18n_tsid == 0) produce a Fatal error:
PHP Fatal error: Call to a member function get_translations() on boolean in .../sites/all/modules/contrib/i18n/i18n_taxonomy/i18n_taxonomy.module on line 1030
1029: $translation_set = i18n_translation_set_load($term->i18n_tsid);
1030: $translations = $translation_set->get_translations();
This is because calling i18n_translation_set_load(0) returns FALSE instead of a i18n_translation_set object.
Attached patch adds a check before calling the get_translations method.
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | i18n_taxonomy-i18n_taxonomy_translate_terms_get_translations-2984895-1.patch | 1.05 KB | vdupom |
Comments
Comment #2
vdupom commentedPatch
Comment #3
vdupom commentedComment #4
jyraya commentedHello,
I experienced the same issue and the patch #2 worked for me.
Comment #6
joseph.olstad