From 929ce2b56621ceda47b910a0fea5452f01812554 Mon Sep 17 00:00:00 2001 From: Thomas Tanghus Date: Sun, 1 Jan 2012 20:06:35 +0100 Subject: [PATCH] Small fixes --- lib/image.php | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/lib/image.php b/lib/image.php index 67290d21f3a..0e1d1ee327f 100644 --- a/lib/image.php +++ b/lib/image.php @@ -55,6 +55,15 @@ class OC_Image { } } + /** + * @brief Determine whether the object contains an image resource. + * returns bool + */ + function empty() { + if(self::$resource && self::$destroy) { + } + } + /** * @brief Prints the image. */ @@ -116,9 +125,6 @@ class OC_Image { * @returns An image resource or false on error */ static public function loadFromFile($imagepath=false) { - if(!is_string($imagepath)) { - return false; - } if(!is_file($imagepath) || !file_exists($imagepath) || !is_readable($imagepath)) { OC_Log::write('core','OC_Image::loadFromFile, couldn\'t load'.$imagepath, OC_Log::DEBUG); return false; -- 2.39.5