Closed (fixed)
Project:
Internationalization
Version:
6.x-1.0-beta4
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
9 Aug 2008 at 19:01 UTC
Updated:
13 Oct 2008 at 18:13 UTC
error message:
Fatal error: Cannot use object of type stdClass as array in […]\sites\all\modules\drupal-contrib\i18n\i18n.module on line 245
This error had also occured in beta2 in line 264.
the function containing line 245 reads:
243 function i18n_language_property($code, $property) {
244 $languages = language_list();
245 return isset($languages[$code][$property]) ? $languages[$code][$property] : NULL;
246 }
Reason:
i18n tries to access a language object as array.
Solution:
245 return isset($languages[$code]->$property) ? $languages[$code]->$property : NULL;
Comments
Comment #1
jose reyero commentedFixed, thanks
Comment #2
aboros@drupal.org commentedjust upgraded i18n to 6.x-1.0-beta4 and i still have the same error in the same line in i18n.module. i thought if this bug was fixed in beta3 it is fixed in beta4, but it's not, i had to edit the .module file to get rid of this bug.
Comment #3
jose reyero commentedIt is fixed in the dev version, right after beta4, I should have updated the bug version to beta4
Comment #4
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.