Skip to content
Snippets Groups Projects
Commit 4094f6f8 authored by Brice Maron's avatar Brice Maron
Browse files

Correct undef variable mistake from prev commit

parent d1e5a56b
No related branches found
No related tags found
No related merge requests found
...@@ -19,12 +19,13 @@ if($calendar_id !== false){ ...@@ -19,12 +19,13 @@ if($calendar_id !== false){
OCP\JSON::error(); OCP\JSON::error();
exit; exit;
} }
$start = (version_compare(PHP_VERSION, '5.3.0', '>='))?DateTime::createFromFormat('U', $_GET['start']):new DateTime('@' . $_GET['start']);
$end = (version_compare(PHP_VERSION, '5.3.0', '>='))?DateTime::createFromFormat('U', $_GET['end']):new DateTime('@' . $_GET['end']);
} }
else { else {
$calendar_id = $_GET['calendar_id']; $calendar_id = $_GET['calendar_id'];
} }
$start = (version_compare(PHP_VERSION, '5.3.0', '>='))?DateTime::createFromFormat('U', $_GET['start']):new DateTime('@' . $_GET['start']);
$end = (version_compare(PHP_VERSION, '5.3.0', '>='))?DateTime::createFromFormat('U', $_GET['end']):new DateTime('@' . $_GET['end']);
$events = OC_Calendar_App::getrequestedEvents($calendar_id, $start, $end); $events = OC_Calendar_App::getrequestedEvents($calendar_id, $start, $end);
$output = array(); $output = array();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment