diff options
author | Bartek Przybylski <bart.p.pl@gmail.com> | 2012-06-06 22:10:09 +0200 |
---|---|---|
committer | Bartek Przybylski <bart.p.pl@gmail.com> | 2012-06-10 13:15:51 +0200 |
commit | c67de113c61faa27c819f928578f4d793e7d3123 (patch) | |
tree | a6cdc1bb570f82a27d1b5148649b3c3ab922f467 /apps/gallery/lib/managers.php | |
parent | 63c02fd595b28065de8f328bd4733ca2a5a9995b (diff) | |
download | nextcloud-server-c67de113c61faa27c819f928578f4d793e7d3123.tar.gz nextcloud-server-c67de113c61faa27c819f928578f4d793e7d3123.zip |
aviod incorrect image size returning in gallery listing
Diffstat (limited to 'apps/gallery/lib/managers.php')
-rw-r--r-- | apps/gallery/lib/managers.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/apps/gallery/lib/managers.php b/apps/gallery/lib/managers.php index 6cb9b420ac6..2444659d0a4 100644 --- a/apps/gallery/lib/managers.php +++ b/apps/gallery/lib/managers.php @@ -32,9 +32,10 @@ class DatabaseManager { \OCP\DB::beginTransaction(); $stmt = \OCP\DB::prepare('INSERT INTO *PREFIX*pictures_images_cache (uid_owner, path, width, height) VALUES (?, ?, ?, ?)'); $stmt->execute(array(\OCP\USER::getUser(), $path, $image->width(), $image->height())); - unset($image); \OCP\DB::commit(); - return $this->getFileData($path); + $ret = array('filepath' => $path, 'width' => $image->width(), 'height' => $image->height()); + unset($image); + return $ret; } private function __construct() {} @@ -93,4 +94,4 @@ class ThumbnailsManager { private function __construct() {} } -?>
\ No newline at end of file +?> |