Code Duplication    Length = 9-9 lines in 2 locations

app/Functions/FunctionsPrintLists.php 2 locations

@@ 764-772 (lines=9) @@
761
			// Husband age
762
			$mdate = $family->getMarriageDate();
763
			$hdate = $husb->getBirthDate();
764
			if ($hdate->isOK() && $mdate->isOK()) {
765
				if ($hdate->gregorianYear() >= 1550 && $hdate->gregorianYear() < 2030) {
766
					$birt_by_decade[(int) ($hdate->gregorianYear() / 10) * 10] .= $husb->getSex();
767
				}
768
				$hage = Date::getAge($hdate, $mdate, 0);
769
				if ($hage >= 0 && $hage <= $max_age) {
770
					$marr_by_age[$hage] .= $husb->getSex();
771
				}
772
			}
773
			$html .= '<td class="center" data=-sort="' . Date::getAge($hdate, $mdate, 1) . '">' . Date::getAge($hdate, $mdate, 2) . '</td>';
774
775
			// Wife name(s)
@@ 807-815 (lines=9) @@
804
			// Wife age
805
			$mdate = $family->getMarriageDate();
806
			$wdate = $wife->getBirthDate();
807
			if ($wdate->isOK() && $mdate->isOK()) {
808
				if ($wdate->gregorianYear() >= 1550 && $wdate->gregorianYear() < 2030) {
809
					$birt_by_decade[(int) ($wdate->gregorianYear() / 10) * 10] .= $wife->getSex();
810
				}
811
				$wage = Date::getAge($wdate, $mdate, 0);
812
				if ($wage >= 0 && $wage <= $max_age) {
813
					$marr_by_age[$wage] .= $wife->getSex();
814
				}
815
			}
816
			$html .= '<td class="center" data-sort="' . Date::getAge($wdate, $mdate, 1) . '">' . Date::getAge($wdate, $mdate, 2) . '</td>';
817
818
			// Marriage date