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

fix(previews): Make thumbnail generation a bit more robust #50009

Merged
merged 1 commit into from
Jan 3, 2025

Conversation

joshtrichards
Copy link
Member

Summary

Makes thumbnail generation a bit more robust for Office / MP3 / Image / Movie types.

Same thing is already being done for other types e.g. HEIC:

$tmpPath = $this->getLocalFile($file);
if ($tmpPath === false) {
\OC::$server->get(LoggerInterface::class)->error(
'Failed to get thumbnail for: ' . $file->getPath(),
['app' => 'core']
);
return null;
}

TODO

Checklist

@kesselb kesselb force-pushed the jtr/preview-thumb-robustness branch 2 times, most recently from 009097b to ef00e96 Compare January 2, 2025 10:58
@kesselb
Copy link
Contributor

kesselb commented Jan 2, 2025

  • Added the imports for LoggerInterface::class
  • \OC::$server->get => \OCP\Server::get
  • Squashed the commits

@kesselb kesselb force-pushed the jtr/preview-thumb-robustness branch from ef00e96 to c23db81 Compare January 2, 2025 15:10
@solracsf

This comment was marked as resolved.

Signed-off-by: Josh <josh.t.richards@gmail.com>
@kesselb kesselb force-pushed the jtr/preview-thumb-robustness branch from c23db81 to 37a9460 Compare January 2, 2025 17:32
@AndyScherzinger AndyScherzinger added this to the Nextcloud 31 milestone Jan 2, 2025
@nickvergessen nickvergessen merged commit 9e18d34 into master Jan 3, 2025
186 of 188 checks passed
@nickvergessen nickvergessen deleted the jtr/preview-thumb-robustness branch January 3, 2025 07:56
@skjnldsv skjnldsv mentioned this pull request Jan 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

An unhandled exception has been thrown
7 participants