Code Duplication    Length = 14-14 lines in 2 locations

Sources/ManageServer.php 2 locations

@@ 715-728 (lines=14) @@
712
			);
713
714
			// Handle min/max/step if necessary
715
			if ($config_var[3] == 'int' || $config_var[3] == 'float')
716
			{
717
				// Default to a min of 0 if one isn't set
718
				if (isset($config_var['min']))
719
					$context['config_vars'][$config_var[0]]['min'] = $config_var['min'];
720
				else
721
					$context['config_vars'][$config_var[0]]['min'] = 0;
722
723
				if (isset($config_var['max']))
724
					$context['config_vars'][$config_var[0]]['max'] = $config_var['max'];
725
726
				if (isset($config_var['step']))
727
					$context['config_vars'][$config_var[0]]['step'] = $config_var['step'];
728
			}
729
730
			// If this is a select box handle any data.
731
			if (!empty($config_var[4]) && is_array($config_var[4]))
@@ 856-869 (lines=14) @@
853
			);
854
855
			// Handle min/max/step if necessary
856
			if ($config_var[0] == 'int' || $config_var[0] == 'float')
857
			{
858
				// Default to a min of 0 if one isn't set
859
				if (isset($config_var['min']))
860
					$context['config_vars'][$config_var[1]]['min'] = $config_var['min'];
861
				else
862
					$context['config_vars'][$config_var[1]]['min'] = 0;
863
864
				if (isset($config_var['max']))
865
					$context['config_vars'][$config_var[1]]['max'] = $config_var['max'];
866
867
				if (isset($config_var['step']))
868
					$context['config_vars'][$config_var[1]]['step'] = $config_var['step'];
869
			}
870
871
			// If this is a select box handle any data.
872
			if (!empty($config_var[2]) && is_array($config_var[2]))