Code Duplication    Length = 8-8 lines in 2 locations

mail/inc/class.mail_ui.inc.php 1 location

@@ 2588-2595 (lines=8) @@
2585
				if (!$eventid) $eventid = -1;
2586
				$event = $calendar_ical->importVCal($attachment['attachment'],(is_array($eventid)?$eventid[0]:$eventid),null,true,0,'',null,$attachment['charset']);
2587
				//error_log(__METHOD__.$event);
2588
				if ((int)$event > 0)
2589
				{
2590
					$vars = array(
2591
						'menuaction'      => 'calendar.calendar_uiforms.edit',
2592
						'cal_id'      => $event,
2593
					);
2594
					Egw::redirect_link('../index.php',$vars);
2595
				}
2596
				//Import failed, download content anyway
2597
			}
2598
			if (strtoupper($attachment['type']) == 'TEXT/X-VCARD' || strtoupper($attachment['type']) == 'TEXT/VCARD')

mail/inc/class.mail_compose.inc.php 1 location

@@ 1911-1918 (lines=8) @@
1908
				if (!$eventid) $eventid = -1;
1909
				$event = $calendar_ical->importVCal($attachment['attachment'],(is_array($eventid)?$eventid[0]:$eventid),null,true);
1910
				//error_log(__METHOD__.$event);
1911
				if ((int)$event > 0)
1912
				{
1913
					$vars = array(
1914
						'menuaction'      => 'calendar.calendar_uiforms.edit',
1915
						'cal_id'      => $event,
1916
					);
1917
					$GLOBALS['egw']->redirect_link('../index.php',$vars);
1918
				}
1919
				//Import failed, download content anyway
1920
			}
1921
			if (strtoupper($attachment['type']) == 'TEXT/X-VCARD' || strtoupper($attachment['type']) == 'TEXT/VCARD')