- Issue created by @21kPiyush
- 🇮🇳India 21kPiyush
I get it working, on line number 134
if ($field->getClass() == '\Drupal\Core\Field\EntityReferenceFieldItemList') {
to
if ($field->getClass() == 'Drupal\Core\Field\EntityReferenceFieldItemList') {
and it work again
- Assigned to 21kPiyush
- Status changed to Needs review
5 months ago 10:34am 26 June 2024 - @loze opened merge request.
- 🇺🇸United States loze Los Angeles
This change fixes this issue for me with Drupal 10.3.0. I've created MR6 with this one line change.
you can grab a patch for composer here https://git.drupalcode.org/project/commerce_pado/-/merge_requests/6.patch
- Issue was unassigned.
- Status changed to RTBC
3 months ago 6:46pm 4 September 2024 - 🇺🇸United States rhovland Oregon
Can confirm this fixes the issue.
For any maintainers wondering why the code checks the field class instead of the field type see #3113263: Add support for Entity Reference Override →
- Status changed to Needs work
3 months ago 6:57pm 4 September 2024 - 🇺🇸United States rhovland Oregon
Nevermind this fix breaks anything older than Drupal 10.3
- @rhovland opened merge request.
- 🇺🇸United States rhovland Oregon
Created a new MR because the other MR was done using the 8.x-1.x branch in the fork and that means I could not check it out because of a name collision.
In 10.2 `$field->getClass()` returns `\Drupal\Core\Field\EntityReferenceFieldItemList`
In 10.3 `$field->getClass()` returns `Drupal\Core\Field\EntityReferenceFieldItemList`This makes the comparison fail.
Instanceof cannot be used here because $field is an instance of `Drupal\field\Entity\FieldConfig``is_a()` is the correct way to check the class and should be more durable.
- Status changed to Needs review
3 months ago 8:40pm 4 September 2024 -
jsacksick →
committed 4095f2da on 8.x-1.x authored by
rhovland →
Issue #3457014 - Drupal 10.3 break
-
jsacksick →
committed 4095f2da on 8.x-1.x authored by
rhovland →
- Status changed to Fixed
3 months ago 6:44am 5 September 2024 Automatically closed - issue fixed for 2 weeks with no activity.