Skip to content
This repository has been archived by the owner on Dec 3, 2022. It is now read-only.

Commit

Permalink
also need the tiny size set for the other resize libraries
Browse files Browse the repository at this point in the history
  • Loading branch information
cash committed May 20, 2013
1 parent 83c2cb9 commit fe2eb7d
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lib/resize.php
Expand Up @@ -211,6 +211,10 @@ function tp_create_imagick_thumbnails($file, $prefix, $filestorename) {
// tiny thumbnail
$thumb->setFilename($prefix."thumb".$filestorename);
$thumbname = $thumb->getFilenameOnFilestore();
if (empty($image_sizes['tiny_image_width'])) {
// sites upgraded from 1.6 may not have this set
$image_sizes['tiny_image_width'] = $image_sizes['tiny_image_height'] = 60;
}
$rtn_code = tp_imagick_resize( $file->getFilenameOnFilestore(),
$thumbname,
$image_sizes['tiny_image_width'],
Expand Down Expand Up @@ -337,6 +341,10 @@ function tp_create_im_cmdline_thumbnails($file, $prefix, $filestorename) {
// tiny thumbnail
$thumb->setFilename($prefix."thumb".$filestorename);
$thumbname = $thumb->getFilenameOnFilestore();
if (empty($image_sizes['tiny_image_width'])) {
// sites upgraded from 1.6 may not have this set
$image_sizes['tiny_image_width'] = $image_sizes['tiny_image_height'] = 60;
}
$rtn_code = tp_im_cmdline_resize( $file->getFilenameOnFilestore(),
$thumbname,
$image_sizes['tiny_image_width'],
Expand Down

0 comments on commit fe2eb7d

Please sign in to comment.