Code Duplication    Length = 5-5 lines in 6 locations

app/Stats.php 6 locations

@@ 2350-2354 (lines=5) @@
2347
				}
2348
			}
2349
		}
2350
		if ($type == 'list') {
2351
			$top10 = implode('', $top10);
2352
		} else {
2353
			$top10 = implode(' ', $top10);
2354
		}
2355
		if (I18N::direction() === 'rtl') {
2356
			$top10 = str_replace(['[', ']', '(', ')', '+'], ['‏[', '‏]', '‏(', '‏)', '‏+'], $top10);
2357
		}
@@ 2427-2431 (lines=5) @@
2424
				$top10[] = '<a href="' . $person->getHtmlUrl() . '">' . $person->getFullName() . '</a> (' . $age . ')';
2425
			}
2426
		}
2427
		if ($type === 'list') {
2428
			$top10 = implode('', $top10);
2429
		} else {
2430
			$top10 = implode('; ', $top10);
2431
		}
2432
		if (I18N::direction() === 'rtl') {
2433
			$top10 = str_replace(['[', ']', '(', ')', '+'], ['&rlm;[', '&rlm;]', '&rlm;(', '&rlm;)', '&rlm;+'], $top10);
2434
		}
@@ 3271-3275 (lines=5) @@
3268
				}
3269
			}
3270
		}
3271
		if ($type === 'list') {
3272
			$top10 = implode('', $top10);
3273
		} else {
3274
			$top10 = implode('; ', $top10);
3275
		}
3276
		if (I18N::direction() === 'rtl') {
3277
			$top10 = str_replace(['[', ']', '(', ')', '+'], ['&rlm;[', '&rlm;]', '&rlm;(', '&rlm;)', '&rlm;+'], $top10);
3278
		}
@@ 4459-4463 (lines=5) @@
4456
				}
4457
			}
4458
		}
4459
		if ($type === 'list') {
4460
			$top10 = implode('', $top10);
4461
		} else {
4462
			$top10 = implode('; ', $top10);
4463
		}
4464
		if (I18N::direction() === 'rtl') {
4465
			$top10 = str_replace(['[', ']', '(', ')', '+'], ['&rlm;[', '&rlm;]', '&rlm;(', '&rlm;)', '&rlm;+'], $top10);
4466
		}
@@ 5096-5100 (lines=5) @@
5093
				}
5094
			}
5095
		}
5096
		if ($type == 'list') {
5097
			$top10 = implode('', $top10);
5098
		} else {
5099
			$top10 = implode('; ', $top10);
5100
		}
5101
		if (I18N::direction() === 'rtl') {
5102
			$top10 = str_replace(['[', ']', '(', ')', '+'], ['&rlm;[', '&rlm;]', '&rlm;(', '&rlm;)', '&rlm;+'], $top10);
5103
		}
@@ 5255-5259 (lines=5) @@
5252
				}
5253
			}
5254
		}
5255
		if ($type === 'list') {
5256
			$top10 = implode('', $top10);
5257
		} else {
5258
			$top10 = implode('; ', $top10);
5259
		}
5260
		if (I18N::direction() === 'rtl') {
5261
			$top10 = str_replace(['[', ']', '(', ')', '+'], ['&rlm;[', '&rlm;]', '&rlm;(', '&rlm;)', '&rlm;+'], $top10);
5262
		}