From d61335a8d31ba8e6f6eb71b73c4158dcecdbfd8e Mon Sep 17 00:00:00 2001 From: "Michael J. Rubinsky" Date: Mon, 15 Feb 2010 12:59:54 -0500 Subject: [PATCH] Add configuration option for no image driver, and have Ansel make sure we have one. --- ansel/lib/Application.php | 4 ++++ horde/config/conf.xml | 5 +++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/ansel/lib/Application.php b/ansel/lib/Application.php index cf27dbb6d..f470d63d9 100644 --- a/ansel/lib/Application.php +++ b/ansel/lib/Application.php @@ -57,6 +57,10 @@ class Ansel_Application extends Horde_Registry_Application */ protected function _init() { + if (!$GLOBALS['conf']['image']['driver']) { + throw new Horde_Exception('You must configure a Horde_Image driver to use Ansel'); + } + // Create a cache object if we need it. if ($GLOBALS['conf']['ansel_cache']['usecache']) { $GLOBALS['cache'] = $GLOBALS['injector']->getInstance('Horde_Cache'); diff --git a/horde/config/conf.xml b/horde/config/conf.xml index 9553a0d28..9afb2ef46 100644 --- a/horde/config/conf.xml +++ b/horde/config/conf.xml @@ -1574,12 +1574,13 @@ Image Manipulation Settings Im + + - - + -- 2.11.0