Fix "PHP Fatal error: Call to undefined method kolab_format_task::to_libcal()" (T1176)
This commit is contained in:
parent
27b1fd0e8c
commit
22e1073307
2 changed files with 24 additions and 24 deletions
|
@ -49,29 +49,6 @@ class kolab_format_event extends kolab_format_xcal
|
||||||
$this->_scheduling_properties = self::$scheduling_properties;
|
$this->_scheduling_properties = self::$scheduling_properties;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Clones into an instance of libcalendaring's extended EventCal class
|
|
||||||
*
|
|
||||||
* @return mixed EventCal object or false on failure
|
|
||||||
*/
|
|
||||||
public function to_libcal()
|
|
||||||
{
|
|
||||||
static $error_logged = false;
|
|
||||||
|
|
||||||
if (class_exists('kolabcalendaring')) {
|
|
||||||
return new EventCal($this->obj);
|
|
||||||
}
|
|
||||||
else if (!$error_logged) {
|
|
||||||
$error_logged = true;
|
|
||||||
rcube::raise_error(array(
|
|
||||||
'code' => 900, 'type' => 'php',
|
|
||||||
'message' => "required kolabcalendaring module not found"
|
|
||||||
), true);
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set event properties to the kolabformat object
|
* Set event properties to the kolabformat object
|
||||||
*
|
*
|
||||||
|
|
|
@ -711,4 +711,27 @@ abstract class kolab_format_xcal extends kolab_format
|
||||||
|
|
||||||
return $reschedule;
|
return $reschedule;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
/**
|
||||||
|
* Clones into an instance of libcalendaring's extended EventCal class
|
||||||
|
*
|
||||||
|
* @return mixed EventCal object or false on failure
|
||||||
|
*/
|
||||||
|
public function to_libcal()
|
||||||
|
{
|
||||||
|
static $error_logged = false;
|
||||||
|
|
||||||
|
if (class_exists('kolabcalendaring')) {
|
||||||
|
return new EventCal($this->obj);
|
||||||
|
}
|
||||||
|
else if (!$error_logged) {
|
||||||
|
$error_logged = true;
|
||||||
|
rcube::raise_error(array(
|
||||||
|
'code' => 900,
|
||||||
|
'message' => "required kolabcalendaring module not found"
|
||||||
|
), true);
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue