diff --git a/include/enotify.php b/include/enotify.php index 50e23930e..63bdd97c2 100644 --- a/include/enotify.php +++ b/include/enotify.php @@ -184,10 +184,10 @@ function notification($params) // First go for the general message // "George Bull's post" - if ($params['activity']['explicit_tagged']) { - $message = '%1$s tagged you on %2$s\'s %3$s %4$s'; - } elseif ($params['activity']['origin_comment']) { + if ($params['activity']['origin_comment']) { $message = '%1$s replied to you on %2$s\'s %3$s %4$s'; + } elseif ($params['activity']['explicit_tagged']) { + $message = '%1$s tagged you on %2$s\'s %3$s %4$s'; } else { $message = '%1$s commented on %2$s\'s %3$s %4$s'; } @@ -198,10 +198,10 @@ function notification($params) // "your post" if ($params['activity']['origin_thread']) { - if ($params['activity']['explicit_tagged']) { - $message = '%1$s tagged you on your %2$s %3$s'; - } elseif ($params['activity']['origin_comment']) { + if ($params['activity']['origin_comment']) { $message = '%1$s replied to you on your %2$s %3$s'; + } elseif ($params['activity']['explicit_tagged']) { + $message = '%1$s tagged you on your %2$s %3$s'; } else { $message = '%1$s commented on your %2$s %3$s'; } @@ -209,10 +209,10 @@ function notification($params) $dest_str = $l10n->t($message, $params['source_name'], $item_post_type, $title); // "their post" } elseif ($item['author-link'] == $params['source_link']) { - if ($params['activity']['explicit_tagged']) { - $message = '%1$s tagged you on their %2$s %3$s'; - } elseif ($params['activity']['origin_comment']) { + if ($params['activity']['origin_comment']) { $message = '%1$s replied to you on their %2$s %3$s'; + } elseif ($params['activity']['explicit_tagged']) { + $message = '%1$s tagged you on their %2$s %3$s'; } else { $message = '%1$s commented on their %2$s %3$s'; } diff --git a/src/Content/Text/BBCode.php b/src/Content/Text/BBCode.php index 51fa08ad3..46eb95bd3 100644 --- a/src/Content/Text/BBCode.php +++ b/src/Content/Text/BBCode.php @@ -967,6 +967,9 @@ class BBCode $attributes['avatar'] = ($author_contact['micro'] ?? '') ?: $attributes['avatar']; $attributes['profile'] = ($author_contact['url'] ?? '') ?: $attributes['profile']; + // $author_contact['url'] could be empty. So then we fill it with the profile + $author_contact['url'] = ($attributes['profile'] ?? '') ?: $author_contact['url']; + if ($attributes['avatar']) { $attributes['avatar'] = ProxyUtils::proxifyUrl($attributes['avatar'], false, ProxyUtils::SIZE_THUMB); }