Code Duplication    Length = 5-5 lines in 2 locations

mod/event_calendar/models/model.php 1 location

@@ 119-123 (lines=5) @@
116
			} else {
117
				$e->end_time = '';
118
			}
119
			if (is_numeric($e->start_date) && is_numeric($e->start_time)) {
120
				// Set start date to the Unix start time, if set.
121
				// This allows sorting by date *and* time.
122
				$e->start_date += $e->start_time*60;
123
			}
124
		} else {
125
			$e->start_time = 0;
126
			$e->end_time = '';

mod/gc_mobile_api/models/event.php 1 location

@@ 586-590 (lines=5) @@
583
			$end_time_exp = explode(':',$endtime);
584
	 		$end_time =60*$end_time_exp[0]+$end_time_exp[1];
585
 			$e->end_time = $end_time;  
586
			if (is_numeric($e->start_date) && is_numeric($e->start_time)) {
587
				// Set start date to the Unix start time, if set.
588
				// This allows sorting by date *and* time.
589
				$e->start_date += $e->start_time*60;
590
			}
591
		 } else {
592
			$e->start_time = '';
593
			$e->end_time = '';