*/
public function calendar_listEvents($startstamp, $endstamp)
{
- $result = $this->_registry->calendar->listEvents(
- $startstamp, // Start
- $endstamp, // End
- null, // Calendar
- false, // Recurrence
- false, // Alarms only
- false, // Show remote
- true, // Hide exception events
- false); // Don't return multi-day events on *each* day
+ try {
+ $result = $this->_registry->calendar->listEvents(
+ $startstamp, // Start
+ $endstamp, // End
+ null, // Calendar
+ false, // Recurrence
+ false, // Alarms only
+ false, // Show remote
+ true, // Hide exception events
+ false); // Don't return multi-day events on *each* day
+ } catch (Exception $e) {
+ return array();
+ }
return $result;
}
*/
public function calendar_listBy($action, $from_ts, $to_ts)
{
- return $this->_registry->calendar->listBy($action, $from_ts, null, $to_ts);
+ try {
+ return $this->_registry->calendar->listBy($action, $from_ts, null, $to_ts);
+ } catch (Exception $e) {
+ return array();
+ }
}
/**
/* Start getting the actual esitmates and outputting the results */
$this->_encoder->startTag(self::GETITEMESTIMATE);
foreach ($collections as $collection) {
+ $this->_state->init($collection);
+ try {
+ $this->_state->loadState($collection['synckey']);
+ } catch (Horde_ActiveSync_Exception $e) {
+ $status[$collection['id']] = self::STATUS_KEYMISM;
+ }
$this->_encoder->startTag(self::RESPONSE);
$this->_encoder->startTag(self::STATUS);
$this->_encoder->content($status[$collection['id']]);
$this->_encoder->content($collection['id']);
$this->_encoder->endTag();
$this->_encoder->startTag(self::ESTIMATE);
-
- $this->_state->init($collection);
- $this->_state->loadState($collection['synckey']);
$sync = $this->_driver->getSyncObject();
$sync->init($this->_state, null, $collection);
-
$this->_encoder->content($sync->GetChangeCount());
$this->_encoder->endTag();
$this->_encoder->endTag();