memory cleanup in gallery
This commit is contained in:
parent
0ba9332358
commit
3f881f1ca5
|
@ -66,9 +66,9 @@ class OC_Gallery_Photo {
|
|||
$stmt->execute(array($newpath, $newAlbumId, $oldAlbumId, $oldpath));
|
||||
}
|
||||
|
||||
public static function getThumbnail($image_name, $owner = null) {
|
||||
if (!$owner) $owner = OC_User::getUser();
|
||||
$save_dir = OC_Config::getValue("datadirectory").'/'. $owner .'/gallery/';
|
||||
public static function getThumbnail($image_name, $owner = null) {
|
||||
if (!$owner) $owner = OC_User::getUser();
|
||||
$save_dir = OC_Config::getValue("datadirectory").'/'. $owner .'/gallery/';
|
||||
$save_dir .= dirname($image_name). '/';
|
||||
$image_path = $image_name;
|
||||
$thumb_file = $save_dir . basename($image_name);
|
||||
|
|
|
@ -81,6 +81,7 @@ class OC_Gallery_Scanner {
|
|||
}
|
||||
}
|
||||
imagepng($thumbnail, OC_Config::getValue("datadirectory").'/'. OC_User::getUser() .'/gallery/' . $albumName.'.png');
|
||||
imagedestroy($thumbnail);
|
||||
}
|
||||
|
||||
public static function createIntermediateAlbums() {
|
||||
|
|
Loading…
Reference in New Issue