Problem/Motivation
In
https://git.drupalcode.org/issue/photoswipe-3232070/-/commit/719e4c31b66...
The following code was added into the admin settings form build:
public function buildForm(array $form, FormStateInterface $form_state) {
$config = $this->configFactory->get('photoswipe.settings');
if ($view_displays = \Drupal::entityTypeManager()->getStorage('entity_view_display')->loadMultiple(NULL)) {
// Loop through all entity view displays:
foreach ($view_displays as $view_display) {
$components = $view_display->getComponents();
foreach ($components as $componentName => $component) {
if (!in_array($component['type'], [
'photoswipe_field_formatter',
'photoswipe_responsive_field_formatter',
])) {
// None of our formatters are used, skip this component:
continue;
}
if (!empty($component['third_party_settings']['fences'])) {
// Explicitely set fences_field_items_wrapper_tag to 'none' if not existing yet.
if (!isset($component['third_party_settings']['fences']['fences_field_items_wrapper_tag'])) {
$component['third_party_settings']['fences']['fences_field_items_wrapper_tag'] = TagManagerInterface::NO_MARKUP_VALUE;
}
// Explicitely set fences_field_items_wrapper_classes to 'none' if not existing yet.
if (!isset($component['third_party_settings']['fences']['fences_field_items_wrapper_classes'])) {
$component['third_party_settings']['fences']['fences_field_items_wrapper_classes'] = TagManagerInterface::NO_MARKUP_VALUE;
}
// Save changes:
$view_display->setComponent($componentName, $component)->save();
}
}
}
}
I have no clue how and why that happened, but it shouldn't :D Let's please remove that immediately :D
Steps to reproduce
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes
Issue fork photoswipe-3380144
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
anybodyComment #4
grevil commentedYea... like discussed internally. No idea, this seems super unrelated.. no idea.
Comment #5
grevil commentedLGTM!
Comment #7
grevil commented