aboutsummaryrefslogtreecommitdiffstats
path: root/include/text.php
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2024-06-21 10:18:40 +0000
committerMario <mario@mariovavti.com>2024-06-21 10:18:40 +0000
commit1c34c354cf48d73863a1e14691f15e678d939023 (patch)
treeef8108e1552164d9bf28f8104a49ecc30fe9abd0 /include/text.php
parent0f02553d129e2bc533cf98a590f3c9e04dc55bf3 (diff)
downloadvolse-hubzilla-1c34c354cf48d73863a1e14691f15e678d939023.tar.gz
volse-hubzilla-1c34c354cf48d73863a1e14691f15e678d939023.tar.bz2
volse-hubzilla-1c34c354cf48d73863a1e14691f15e678d939023.zip
fix issue where event items were parsed multiple times
Diffstat (limited to 'include/text.php')
-rw-r--r--include/text.php13
1 files changed, 9 insertions, 4 deletions
diff --git a/include/text.php b/include/text.php
index b9ec90e92..b03e2d1a9 100644
--- a/include/text.php
+++ b/include/text.php
@@ -2082,10 +2082,15 @@ function prepare_text($text, $content_type = 'text/bbcode', $opts = false) {
default:
require_once('include/bbcode.php');
- if(stristr($text, '[nosmile]'))
- $s = bbcode($text, ((is_array($opts)) ? $opts : [] ));
- else
- $s = smilies(bbcode($text, ((is_array($opts)) ? $opts : [] )));
+ // events are handled in format_event_obj()
+ if (empty($opts['is_event_item'])) {
+ if(stristr($text, '[nosmile]')) {
+ $s = bbcode($text, ((is_array($opts)) ? $opts : [] ));
+ }
+ else {
+ $s = smilies(bbcode($text, ((is_array($opts)) ? $opts : [] )));
+ }
+ }
$s = zidify_links($s);