aboutsummaryrefslogtreecommitdiff
path: root/app/Models/Entry.php
diff options
context:
space:
mode:
authorGravatar Alexandre Alapetite <alexandre@alapetite.fr> 2024-09-09 10:36:52 +0200
committerGravatar GitHub <noreply@github.com> 2024-09-09 10:36:52 +0200
commitaf0498fe679fe00f4b0ea07bb55c15e6deca8840 (patch)
treebd733fdbbedd84c6c76469c74c8bec822722b2cd /app/Models/Entry.php
parentaf37d88d859b4301018c4a0351574d485903bd32 (diff)
Fix auto-read tags (#6790)
fix https://github.com/FreshRSS/FreshRSS/issues/6788
Diffstat (limited to 'app/Models/Entry.php')
-rw-r--r--app/Models/Entry.php4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/Models/Entry.php b/app/Models/Entry.php
index 415bc0235..a4b8e1366 100644
--- a/app/Models/Entry.php
+++ b/app/Models/Entry.php
@@ -670,6 +670,7 @@ HTML;
foreach ($filter->getTags() as $tag2) {
$found = false;
foreach ($this->tags as $tag1) {
+ $tag1 = ltrim($tag1, '#');
if (strcasecmp($tag1, $tag2) === 0) {
$found = true;
break;
@@ -682,6 +683,7 @@ HTML;
foreach ($filter->getTagsRegex() as $tag2) {
$found = false;
foreach ($this->tags as $tag1) {
+ $tag1 = ltrim($tag1, '#');
if (preg_match($tag2, $tag1) === 1) {
$found = true;
break;
@@ -694,6 +696,7 @@ HTML;
foreach ($filter->getNotTags() as $tag2) {
$found = false;
foreach ($this->tags as $tag1) {
+ $tag1 = ltrim($tag1, '#');
if (strcasecmp($tag1, $tag2) === 0) {
$found = true;
break;
@@ -706,6 +709,7 @@ HTML;
foreach ($filter->getNotTagsRegex() as $tag2) {
$found = false;
foreach ($this->tags as $tag1) {
+ $tag1 = ltrim($tag1, '#');
if (preg_match($tag2, $tag1) === 1) {
$found = true;
break;