Skip to content
New issue

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

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

Already on GitHub? # to your account

Do not count mangas as part of categories that aren't in the library #574

Conversation

schroda
Copy link
Collaborator

@schroda schroda commented Jun 9, 2023

Otherwise, the "size" calculation of categories is wrong, since it includes mangas that aren't in the library anymore and won't be returned in the list of mangas of a category

@AriaMoradi
Copy link
Member

AriaMoradi commented Jun 9, 2023

This is tachiyomi behavior that we are reproducing. We should try working around this, unless there is a good reason to not to.
(I believe this behavior was originally intended to keep your categories for when adding manga to library again)

cc: @Syer10

@Syer10
Copy link
Collaborator

Syer10 commented Jun 9, 2023

Yes this is intenional behavior, I would suggest modifying the size calculation to only include in-library manga instead.

@schroda schroda force-pushed the fix/manga_still_in_category_after_removal_from_library branch from 36a0142 to cc21bfa Compare June 9, 2023 13:58
@schroda
Copy link
Collaborator Author

schroda commented Jun 9, 2023

changed

but what is the use case of this behaviour - that the categories are "restored" when adding it back to the library?

Otherwise, the returned "size" of a property doesn't match the actual manga list, since that list only includes mangas from the library
@schroda schroda force-pushed the fix/manga_still_in_category_after_removal_from_library branch from cc21bfa to 84c6b84 Compare June 9, 2023 14:00
@schroda schroda changed the title Delete manga category mapping on removal from library Do not count mangas as part of categories that aren't in the library Jun 9, 2023
@Syer10
Copy link
Collaborator

Syer10 commented Jun 9, 2023

Yes, instead of using the default categories, it should use the previously selected categories

@AriaMoradi AriaMoradi merged commit b59af68 into Suwayomi:master Jun 9, 2023
@schroda schroda deleted the fix/manga_still_in_category_after_removal_from_library branch June 18, 2023 14:37
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants