Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Problem/Motivation
Got this error when I clicked on a Enable/Disable translation link on the bottom of admin/structure/types/manage/article/fields/node.article.body/field
.
Fatal error: Call to a member function isFieldTranslatable() on a non-object in core\modules\content_translation\lib\Drupal\content_translation\Form\TranslatableForm.php on line 46
Proposed resolution
No crash
Remaining tasks
Bugfix
User interface changes
None
API changes
None
Related Issues
?
Comments
Comment #1
hass CreditAttribution: hass commentedComment #2
plachThis must be a leftover of the Field NG refactorings. Patch coming soon.
Comment #3
plachOh, this is going to be removed in #2076445: Make sure language codes for original field values always match entity language regardless of field translatability.
Comment #4
hass CreditAttribution: hass commentedComment #5
Gábor Hojtsy@hass: also in the interim, #1831608: Show or hide the "Make field translatable" checkbox on the add field form depending on translatability provides a solution for this and adds more test coverage AFAIS.
Comment #6
yched CreditAttribution: yched commented#2076445: Make sure language codes for original field values always match entity language regardless of field translatability is in, is there still something to fix here ?
Comment #7
amateescu CreditAttribution: amateescu commentedTested the step from the OP and I cannot reproduce the error anymore.