Skip to content

Commit

Permalink
fix logics
Browse files Browse the repository at this point in the history
  • Loading branch information
folix-01 committed Jul 31, 2024
1 parent a09c265 commit 7841f17
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/collective/feedback/restapi/services/get.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,11 @@ def get_data(self):

# Use has_unread filter
if has_undread is not None:
has_undread = not (has_undread == "false") and has_undread == "true"
if feedback["has_unread"] != has_undread:
pages_to_remove.append(uid)
if has_undread in ("true", "false"):
has_undread = not (has_undread == "false") and has_undread == "true"

if feedback["has_unread"] != has_undread:
pages_to_remove.append(uid)

for uid in pages_to_remove:
del feedbacks[uid]
Expand Down

0 comments on commit 7841f17

Please sign in to comment.