From 4708dd184c4f0df6d9cbeec3c93bec52d3ab87c7 Mon Sep 17 00:00:00 2001 From: Chuck Hagenbuch Date: Fri, 4 Jun 2010 15:48:16 -0400 Subject: [PATCH] Don't throw an error if there aren't any interfaces set for some reason --- framework/Core/lib/Horde/Registry.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/framework/Core/lib/Horde/Registry.php b/framework/Core/lib/Horde/Registry.php index b519f1b3e..33f0ee091 100644 --- a/framework/Core/lib/Horde/Registry.php +++ b/framework/Core/lib/Horde/Registry.php @@ -648,9 +648,11 @@ class Horde_Registry public function listAPIs() { if (empty($this->_apis)) { - foreach (array_keys($this->_cache['interfaces']) as $interface) { - list($api,) = explode('/', $interface, 2); - $this->_apis[$api] = true; + if (!empty($this->_cache['interfaces'])) { + foreach (array_keys($this->_cache['interfaces']) as $interface) { + list($api,) = explode('/', $interface, 2); + $this->_apis[$api] = true; + } } } -- 2.11.0