Code Duplication    Length = 12-15 lines in 2 locations

Sources/Profile-Actions.php 1 location

@@ 333-347 (lines=15) @@
330
					'value' => $txt['profile_warning_previous_reason'],
331
				),
332
				'data' => array(
333
					'function' => function($warning) use ($scripturl, $txt)
334
					{
335
						$ret = '
336
						<div class="floatleft">
337
							' . $warning['reason'] . '
338
						</div>';
339
340
						if (!empty($warning['id_notice']))
341
							$ret .= '
342
						<div class="floatright">
343
							<a href="' . $scripturl . '?action=moderate;area=notice;nid=' . $warning['id_notice'] . '" onclick="window.open(this.href, \'\', \'scrollbars=yes,resizable=yes,width=400,height=250\');return false;" target="_blank" class="new_win" title="' . $txt['profile_warning_previous_notice'] . '"><span class="generic_icons filter centericon"></span></a>
344
						</div>';
345
346
						return $ret;
347
					},
348
				),
349
			),
350
			'level' => array(

Sources/ModerationCenter.php 1 location

@@ 1530-1541 (lines=12) @@
1527
					'value' => $txt['profile_warning_previous_reason'],
1528
				),
1529
				'data' => array(
1530
					'function' => function($rowData) use ($scripturl, $txt)
1531
					{
1532
						$output = '
1533
							<div class="floatleft">
1534
								' . $rowData['reason'] . '
1535
							</div>';
1536
1537
						if (!empty($rowData['id_notice']))
1538
							$output .= '
1539
								&nbsp;<a href="' . $scripturl . '?action=moderate;area=notice;nid=' . $rowData['id_notice'] . '" onclick="window.open(this.href, \'\', \'scrollbars=yes,resizable=yes,width=400,height=250\');return false;" target="_blank" class="new_win" title="' . $txt['profile_warning_previous_notice'] . '"><span class="generic_icons filter centericon"></span></a>';
1540
						return $output;
1541
					},
1542
				),
1543
			),
1544
			'points' => array(