Skip to content

Do early return so we don't try to generate a thumbnail when we cannot.#3780

Merged
marcellamaki merged 1 commit intolearningequality:hotfixesfrom
rtibbles:epubthumbnail
Oct 31, 2022
Merged

Do early return so we don't try to generate a thumbnail when we cannot.#3780
marcellamaki merged 1 commit intolearningequality:hotfixesfrom
rtibbles:epubthumbnail

Conversation

@rtibbles
Copy link
Copy Markdown
Member

Summary

Description of the change(s) you made

  • We do a check to see if we have the information we need to generate a thumbnail, but then try to generate the thumbnail anyway
  • This fixes that by returning early

Manual verification steps performed

  1. Upload the epub in the archive here: https://github.com/learningequality/studio/files/9887092/TestGoogleEPUB.zip
  2. Try to generate a thumbnail.
  3. Confirm it tells the user there is an error, but no console errors are shown.

Fixes #3770

@rtibbles rtibbles requested a review from marcellamaki October 28, 2022 16:17
Copy link
Copy Markdown
Member

@marcellamaki marcellamaki left a comment

Choose a reason for hiding this comment

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

Change makes sense and manual testing working as expected

@marcellamaki marcellamaki merged commit afa6d24 into learningequality:hotfixes Oct 31, 2022
@pcenov
Copy link
Copy Markdown
Member

pcenov commented Nov 3, 2022

I confirm, no errors in the console when a thumbnail is not being generated now for that type of EPUBs.

@bjester bjester mentioned this pull request Nov 9, 2022
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.

3 participants