Skip to content

Commit

Permalink
fix(textareafield): html escaping problem
Browse files Browse the repository at this point in the history
  • Loading branch information
btry committed Feb 16, 2022
1 parent 0b523a7 commit 63eac85
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion inc/field/textareafield.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,10 @@ public function parseAnswerValues($input, $nonDestructive = false): bool {

public function getValueForTargetText($domain, $richText): ?string {
$value = $this->value;
if (!$richText) {
if ($richText) {
$value = Sanitizer::unsanitize($value);
$value = Html::entities_deep($value);
} else {
$value = Sanitizer::unsanitize($value);
$value = strip_tags($value);
}
Expand Down

0 comments on commit 63eac85

Please sign in to comment.