Translatable plugin default settings shouldn't be run through t()

Created on 12 July 2023, 12 months ago

Problem/Motivation

I'm not experiencing a difficulty, but noticed that \Drupal\paragraphs\Plugin\Field\FieldWidget\ParagraphsWidget::defaultSettings() and \Drupal\paragraphs\Plugin\Field\FieldWidget\InlineParagraphsWidget::defaultSettings() run both title and title_plural through t() which I don't think is necessary for translatable settings stored in config.

I'm not 100% confident I'm on the right track and asked on Slack where there was a response suggesting this is the right way to go.

Thanks!

Steps to reproduce

Proposed resolution

Don't use t().

Remaining tasks

User interface changes

API changes

Data model changes

πŸ› Bug report
Status

Needs review

Version

1.0

Component

Code

Created by

πŸ‡¬πŸ‡§United Kingdom AndyF

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

Comments & Activities

Production build 0.69.0 2024