- Issue created by @joseph.olstad
- @priti197 opened merge request.
- 🇨🇦Canada joseph.olstad
patch #3 is garbage however the merge request patch does work.
Basically fixes the issue as described.
- 🇨🇦Canada joseph.olstad
Thanks @priti197
Here's a link to the MR patch file
https://git.drupalcode.org/project/dynamic_entity_reference/-/merge_requ... - Issue was unassigned.
- Status changed to RTBC
4 months ago 11:12am 31 January 2025 - 🇺🇸United States damienmckenna NH, USA
I believe this resolves another problem I ran into: 🐛 TypeError: uasort(): Argument #1 ($array) must be of type array, null given in uasort() Active
patch #3 doesn't work for me.
Partialy work this code. Allow save configuration if select 2 bundles.
public static function getTargetTypes(array $settings) { $labels = \Drupal::service('entity_type.repository')->getEntityTypeLabels(TRUE); $options = array_filter(array_keys($labels[(string) t('Content', [], ['context' => 'Entity type group'])]), function ($entity_type_id) { return static::entityHasIntegerId($entity_type_id); }); if (!empty($settings['entity_type_ids'])) { if (!empty($settings['exclude_entity_types'])) { return array_diff($options, $settings['entity_type_ids'] ?: ['default']); } else { return array_intersect($options, $settings['entity_type_ids'] ?: ['default']); } } else { return $options; } }
- 🇦🇺Australia elimw
The changes in the merge request don't fully work for me. I still get this error on every odd click which selects an entity type.