Code Duplication    Length = 16-16 lines in 2 locations

app/Stats.php 2 locations

@@ 2262-2277 (lines=16) @@
2259
		}
2260
		$row    = $rows[0];
2261
		$person = Individual::getInstance($row['id'], $this->tree);
2262
		switch ($type) {
2263
			default:
2264
			case 'full':
2265
				if ($person->canShowName()) {
2266
					$result = $person->formatList('span', false, $person->getFullName());
2267
				} else {
2268
					$result = I18N::translate('This information is private and cannot be shown.');
2269
				}
2270
				break;
2271
			case 'age':
2272
				$result = I18N::number((int) ($row['age'] / 365.25));
2273
				break;
2274
			case 'name':
2275
				$result = '<a href="' . $person->getHtmlUrl() . '">' . $person->getFullName() . '</a>';
2276
				break;
2277
		}
2278
2279
		return $result;
2280
	}
@@ 4400-4415 (lines=16) @@
4397
		}
4398
		$row    = $rows[0];
4399
		$family = Family::getInstance($row['id'], $this->tree);
4400
		switch ($type) {
4401
			default:
4402
			case 'full':
4403
				if ($family->canShow()) {
4404
					$result = $family->formatList('span', false, $family->getFullName());
4405
				} else {
4406
					$result = I18N::translate('This information is private and cannot be shown.');
4407
				}
4408
				break;
4409
			case 'size':
4410
				$result = I18N::number($row['tot']);
4411
				break;
4412
			case 'name':
4413
				$result = '<a href="' . $family->getHtmlUrl() . '">' . $family->getFullName() . '</a>';
4414
				break;
4415
		}
4416
4417
		return $result;
4418
	}