Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Counted all favorites #6224

Open
wants to merge 13 commits into
base: edge
Choose a base branch
from
Open

Conversation

math-GH
Copy link
Contributor

@math-GH math-GH commented Mar 21, 2024

IMHO the total number of favorite articles is useless. There is no similar thing that shows up the absolut number of articles. Furthermore the number cannot be styled.

This PR deletes the number. It reduces 1 SQL query in each page load of a view.

Before:
grafik

After:
grafik

@math-GH math-GH added System care Everything related to the system care UX User experience labels Mar 21, 2024
@math-GH math-GH added this to the 1.24.0 milestone Mar 21, 2024
@Frenzie
Copy link
Member

Frenzie commented Mar 21, 2024

I don't think it's comparable to the total number of articles. The total number of articles is a meaningless consequence of a few settings while the number of favorites is something that was quite purposefully caused by the user. But I don't mean that as an argument to keep that number, or at the very least not in that location.

@math-GH
Copy link
Contributor Author

math-GH commented Mar 21, 2024

I don't think it's comparable to the total number of articles. The total number of articles is a meaningless consequence of a few settings while the number of favorites is something that was quite purposefully caused by the user. But I don't mean that as an argument to keep that number, or at the very least not in that location.

Thanks for your opinion. Nice argumentation, that could be similar to the labels, isn't it?

@math-GH
Copy link
Contributor Author

math-GH commented Mar 21, 2024

It became a little refactoring.

countUnreadReadFavorites() is splitted now into countUnreadFavorites() and countFavorites() (countFavorites() is only used by user-info.php). The return values are now simple int instead of arrays.

@Frenzie
Copy link
Member

Frenzie commented Mar 22, 2024

Thanks for your opinion. Nice argumentation, that could be similar to the labels, isn't it?

Yes, I would agree that conceptually favorite is a special label.

@Alkarex Alkarex modified the milestones: 1.24.0, 1.25.0 Apr 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
System care Everything related to the system care UX User experience
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants