Skip to content

Commit 5f49d0b

Browse files
committed
Fix stripping of html tags in $description
1 parent 08f994c commit 5f49d0b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Templates/Document/View.phtml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ if ($object)
3535
$description = filter_var($brief, FILTER_SANITIZE_FULL_SPECIAL_CHARS);
3636
if (empty($description))
3737
{
38-
$description = rtrim(StringProcessor::stripUpTo(StringProcessor::stripUpTo(trim(filter_var($content, FILTER_SANITIZE_FULL_SPECIAL_CHARS)), "\n", 300), '. ', 300), '.');
38+
$description = rtrim(StringProcessor::stripUpTo(StringProcessor::stripUpTo(trim(strip_tags($content)), "\n", 128), '. ', 128), '.');
3939
}
4040
}
4141
$edit_url = UrlFormatter::format('/document/edit?id=' . rawurlencode($object_id));

0 commit comments

Comments
 (0)