Speed up listing alarms (Request #8638).
authorJan Schneider <jan@horde.org>
Wed, 14 Oct 2009 13:40:00 +0000 (15:40 +0200)
committerJan Schneider <jan@horde.org>
Wed, 14 Oct 2009 13:40:13 +0000 (15:40 +0200)
kronolith/docs/CHANGES
kronolith/lib/Api.php

index 3542f8c..b4d86a8 100644 (file)
@@ -24,6 +24,7 @@ v3.0-git
 v2.3.3-cvs
 ----------
 
+[jan] Speed up listing alarms (Request #8638).
 [jan] Simplify and improve portability of listing events without date limits
       in the SQL driver (Bug #8590).
 [mjr] Fix issue that caused the default alarm time to be applied to 
index 7916d01..71a593a 100644 (file)
@@ -1131,6 +1131,9 @@ class Kronolith_Api extends Horde_Registry_Api
             return $alarms;
         }
         foreach ($alarms as $calendar => $cal_alarms) {
+            if (!$cal_alarms) {
+                continue;
+            }
             $share = $GLOBALS['kronolith_shares']->getShare($calendar);
             if (is_a($share, 'PEAR_Error')) {
                 continue;