Code Duplication    Length = 5-5 lines in 2 locations

sources/admin/ManageFeatures.controller.php 2 locations

@@ 645-649 (lines=5) @@
642
						'class' => 'centertext',
643
					),
644
					'data' => array(
645
						'function' => function ($rowData) {
646
							$isChecked = $rowData['disabled'] ? '' : ' checked="checked"';
647
							$onClickHandler = $rowData['can_show_register'] ? sprintf('onclick="document.getElementById(\'reg_%1$s\').disabled = !this.checked;"', $rowData['id']) : '';
648
							return sprintf('<input type="checkbox" name="active[]" id="active_%1$s" value="%1$s" class="input_check" %2$s %3$s />', $rowData['id'], $isChecked, $onClickHandler);
649
						},
650
						'style' => 'width: 20%;',
651
						'class' => 'centertext',
652
					),
@@ 660-664 (lines=5) @@
657
						'class' => 'centertext',
658
					),
659
					'data' => array(
660
						'function' => function ($rowData) {
661
							$isChecked = $rowData['on_register'] && !$rowData['disabled'] ? ' checked="checked"' : '';
662
							$isDisabled = $rowData['can_show_register'] ? '' : ' disabled="disabled"';
663
							return sprintf('<input type="checkbox" name="reg[]" id="reg_%1$s" value="%1$s" class="input_check" %2$s %3$s />', $rowData['id'], $isChecked, $isDisabled);
664
						},
665
						'style' => 'width: 20%;',
666
						'class' => 'centertext',
667
					),