gunnar: server/php-kolab/Kolab_Filter/Filter Resource.php,1.5,1.6

cvs at kolab.org cvs at kolab.org
Tue Feb 26 22:35:04 CET 2008


Author: gunnar

Update of /kolabrepository/server/php-kolab/Kolab_Filter/Filter
In directory doto:/tmp/cvs-serv22452/Filter

Modified Files:
	Resource.php 
Log Message:
Fix undefined variables.

Index: Resource.php
===================================================================
RCS file: /kolabrepository/server/php-kolab/Kolab_Filter/Filter/Resource.php,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- Resource.php	28 Nov 2007 15:36:59 -0000	1.5
+++ Resource.php	26 Feb 2008 21:35:02 -0000	1.6
@@ -435,26 +435,21 @@
         return $result;
     }
 
-    // If this call is purely to cache the f/b list then we don't need to
-    // bother parsing the VFB file
-    if (!$cache) {
-        $iCalendar = &new Horde_iCalendar();
-        $iCalendar->parsevCalendar($text);
-        $vfb = &$iCalendar->findComponent('VFREEBUSY');
-
-        if ($vfb === false) {
-            Horde::logMessage(sprintf(_("Invalid or no free/busy information available for %s"), 
-                                      $resource), 
-                              __FILE__, __LINE__, PEAR_LOG_ERR);
-            //shutdown();
-            $result = false;
-            return $result;
-        }
-
-        $vfb->simplify();
-
-        return $vfb;
+    $iCalendar = &new Horde_iCalendar();
+    $iCalendar->parsevCalendar($text);
+    $vfb = &$iCalendar->findComponent('VFREEBUSY');
+   
+    if ($vfb === false) {
+        Horde::logMessage(sprintf(_("Invalid or no free/busy information available for %s"), 
+                                  $resource), 
+                          __FILE__, __LINE__, PEAR_LOG_ERR);
+        //shutdown();
+        $result = false;
+        return $result;
     }
+    $vfb->simplify();
+
+    return $vfb;
 }
 
 function sendITipReply($cn,$resource, $itip, $type = RM_ITIP_ACCEPT)
@@ -832,8 +827,8 @@
 
     $recurrence = false;
 
-    $kolab_xml = Horde_DOM_Document::factory(array('xml' => $xml_text));
-    if (is_a($result, 'PEAR_Error')) {
+    $kolab_xml = Horde_DOM_Document::factory();
+    if (is_a($kolab_xml, 'PEAR_Error')) {
         // There were errors building the xml document
         Horde::logMessage(sprintf(_("Error building xml document: %s"), 
                                   $result->getMessage()),





More information about the commits mailing list