Skip to content
This repository has been archived by the owner on Nov 25, 2020. It is now read-only.

Commit

Permalink
Fix image magick preview on multiple page office file
Browse files Browse the repository at this point in the history
  • Loading branch information
c12simple committed Feb 22, 2016
1 parent 6bad1f4 commit f706186
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/plugins/editor.imagick/class.IMagickPreviewer.php
Expand Up @@ -321,7 +321,7 @@ public function generateJpegsCallback($masterFile, $targetFile)
if (is_array($out) && count($out)) {
throw new AJXP_Exception(implode("\n", $out));
}
if(!is_file($tmpFileThumb)){
if(!(is_file($tmpFileThumb) || is_file(str_replace(".jpg", "-0.jpg", $tmpFileThumb)))){
throw new AJXP_Exception("Error while converting PDF file to JPG thumbnail. Return code '$return'. Command used '".$this->getFilteredOption("IMAGE_MAGICK_CONVERT")."': is the binary at the correct location? Is the server allowed to use it?");
}
if (!$this->extractAll) {
Expand Down

0 comments on commit f706186

Please sign in to comment.