- Issue created by @Daniel_Rempe
- Status changed to Fixed
9 months ago 11:23am 20 March 2024 Automatically closed - issue fixed for 2 weeks with no activity.
Using the SDC Display module to render a paragraph causes the following warning:
Warning: Undefined array key "#view_mode" in Drupal\paragraphs\ParagraphViewBuilder->buildMultiple()
(Line 23 in .../web/modules/contrib/paragraphs/src/ParagraphViewBuilder.php)
Except of the warning everything works fine as expected. (Thank you for this great module :) )
Configure a paragraph type with just the default display mode and assign its fields to a sdc component. Using the paragraph type on any node type leads to the warning.
It seems to be caused by paragraphs function that expected the "#view_mode" key in the build array. Adding the key in sdc_display_entity_view_alter solves the issue for me.
Is this the right way of fixing this? Or should paragraphs test for the key?
Fixed
1.0
Code
Automatically closed - issue fixed for 2 weeks with no activity.