diff --git a/CHANGELOG.md b/CHANGELOG.md index 021b976..2e0eb2c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,11 @@ Changelog ========= +0.0.21 (2014-05-07) +------------------- + +- Merge branch 'master' of dimti.ru:lib/Image. [Alexander Demidov] + 0.0.20 (2014-05-07) ------------------- diff --git a/Upload.class.php b/Upload.class.php index 6684c62..4e4ccfe 100644 --- a/Upload.class.php +++ b/Upload.class.php @@ -11,7 +11,9 @@ abstract class Upload public static function &getGreagwarImage($file_path) { $greagwar_image = new GreagwarImage($file_path); - $greagwar_image->setCacheDir(Config::get('PATH_WEB_ROOT') . DIRECTORY_SEPARATOR . self::$dir_image_cache); + $config_upload = Config::get('Upload'); + $dir_image_cache = $config_upload ? $config_upload->dir_image_cache : self::$dir_image_cache; + $greagwar_image->setCacheDir(Config::get('PATH_WEB_ROOT') . DIRECTORY_SEPARATOR . $dir_image_cache); return $greagwar_image; }