Comments with HTML are not properly escaped

Created on 5 May 2023, over 1 year ago
Updated 8 May 2023, over 1 year ago

Problem/Motivation

Comments are always Html::escape even with setting Allow a comment per time slot: Allow comments (HTML tags possible)

Steps to reproduce

Allow a comment per time slot: Allow comments (HTML tags possible)
Add a comment that contains HTML

Proposed resolution

```
+ if (1 === (int)$field_settings['comment']) {
+ $info['comments'] = array_map('Drupal\Component\Utility\Html::normalize', $info['comments']);
+ } else {
+ $info['comments'] = array_map('Drupal\Component\Utility\Html::escape', $info['comments']);
+ }
```

Remaining tasks

none

User interface changes

none

API changes

none

Data model changes

none

🐛 Bug report
Status

Fixed

Version

1.8

Component

Code - formatter

Created by

🇺🇸United States ian.ssu

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

Comments & Activities

Production build 0.71.5 2024