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

Light refactoring in ContentManager and ContentManagerModel #1049

Merged
merged 9 commits into from
Mar 8, 2024

Conversation

veloman-yunkan
Copy link
Collaborator

This is the next (this time a relatively small) installment of the refactoring changes done in the context of #1038.

... and stopped passing it (as the second parameter) into
ContentManagerModel::createNode().
"faviconMimeType" is not used anywhere but is responsible for some of the
too much clutter in ContentManager::getBookInfos().
One small difference of getFaviconUrl() from the piece of code it was
created from is that, in case the book doesn't contain an illustration,
an empty string is returned directly rather than via a confusing
default-constructed Illustration object.
The only justified check for the availability of download functionality
is in the initiation of the download action
(`ContentManager::downloadBook()`) - if no download is started then
(assuming otherwise correct code) it should be impossible to pause,
resume or cancel one.
Got rid of unneeded flexibility in ContentManager::getDownloadInfo()
Copy link
Member

@mgautierfr mgautierfr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yet again, LGTM

@mgautierfr mgautierfr merged commit bd0f896 into main Mar 8, 2024
4 checks passed
@mgautierfr mgautierfr deleted the refactoring branch March 8, 2024 14:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants