@@ -81,7 +81,7 @@ function draw_print($template_p) {
81
81
foreach ($ new_val as $ new_key2 => $ new_val2 ) {
82
82
if (isset ($ seen_events [$ new_key2 ])) {
83
83
// Include in list if we've already seen it AND
84
- // (it spans more than one day OR it's a recurring event)
84
+ // (it spans more than one day OR it's a recurring event)
85
85
if (($ new_val2 ['spans_day ' ] != 1 ) && (!isset ($ new_val2 ['recur ' ]))) {
86
86
continue ;
87
87
}
@@ -378,7 +378,7 @@ function draw_week($template_p) {
378
378
$ loop_hours = trim ($ match2 [1 ]);
379
379
$ loop_event = trim ($ match3 [1 ]);
380
380
381
- $ event_length = array ();
381
+ $ event_length = array ();
382
382
$ border = 0 ;
383
383
preg_match ('/([0-9]{4})([0-9]{2})([0-9]{2})/ ' , $ getdate , $ day_array2 );
384
384
$ this_day = $ day_array2 [3 ];
@@ -445,7 +445,7 @@ function draw_week($template_p) {
445
445
}
446
446
$ j ++;
447
447
}
448
- if ($ j == sizeof (@ $ event_length [$ thisday ])) {
448
+ if (empty ( $ event_length [ $ thisday ]) || $ j == count ( $ event_length [$ thisday ])) {
449
449
$ event_length [$ thisday ][] = array ('length ' => ($ drawEvent ['draw_length ' ] / $ phpiCal_config ->gridLength ), 'key ' => $ eventKey , 'overlap ' => $ loopevent ['event_overlap ' ],'state ' => 'begin ' );
450
450
}
451
451
}
@@ -1096,7 +1096,7 @@ function monthbottom() {
1096
1096
foreach ($ event_times as $ uid => $ val ) {
1097
1097
if (isset ($ seen_events [$ uid ])) {
1098
1098
// Include in list if we've already seen it AND
1099
- // (it spans more than one day OR it's a recurring event)
1099
+ // (it spans more than one day OR it's a recurring event)
1100
1100
if ((@$ val ['spans_day ' ] != 1 ) && (!isset ($ val ['recur ' ]))) {
1101
1101
continue ;
1102
1102
}
0 commit comments