fix gallery scan when an image cant be loaded
This commit is contained in:
parent
73c6db5c8e
commit
eb3ec05f88
1 changed files with 1 additions and 1 deletions
|
@ -78,8 +78,8 @@ class OC_Gallery_Scanner {
|
|||
$image = OC_Gallery_Photo::getThumbnail($files[$i]);
|
||||
if ($image && $image->valid()) {
|
||||
imagecopyresampled($thumbnail, $image->resource(), $i*200, 0, 0, 0, 200, 200, 200, 200);
|
||||
$image->destroy();
|
||||
}
|
||||
$image->destroy();
|
||||
}
|
||||
imagepng($thumbnail, OC_Config::getValue("datadirectory").'/'. OC_User::getUser() .'/gallery/' . $albumName.'.png');
|
||||
imagedestroy($thumbnail);
|
||||
|
|
Loading…
Reference in a new issue