Swiper formatter breaks on custom fields in views

Created on 3 October 2022, about 2 years ago
Updated 20 October 2024, about 1 month ago

Problem/Motivation

Hello, I try to use Swiper formatter for my view where I used Global "Custom text" field, and Swiper don't open settings in such configuration.

Steps to reproduce

Try to add Custom text field to the Swiper view.

Proposed resolution

The problem is here: SwiperFormatterStyle.php

$field_storage_definitions = $this->entityFieldManager->getFieldStorageDefinitions($field->definition['entity_type']);

You need to wrap it up with

if (!empty($field->definition['entity_type'])) {
  $field_storage_definitions = $this->entityFieldManager->getFieldStorageDefinitions($field->definition['entity_type']);
}
🐛 Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

🇷🇺Russia Andrew Answer Novosibirsk

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024