Skip to content

Commit

Permalink
Merge pull request #294 from koo04/master
Browse files Browse the repository at this point in the history
Fixes redundant checks.
  • Loading branch information
Koo committed Nov 16, 2014
2 parents efc144a + 16b0c3f commit ae442d3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion panel/admin/node/ajax/ports/add_port.php
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
if(!isset($_POST['add_ports'], $_POST['add_ports_ip']))
Components\Page::redirect('../../view.php?id='.$_POST['add_ports_node'].'&tab=allocation');

if(!preg_match('/^[\d,]+$/', $_POST['add_ports']) && !preg_match('/^[\d-]+$/', $_POST['add_ports']) && !preg_match('/^[\d-,]+$/', $_POST['add_ports']))
if(!preg_match('/^[\d-,]+$/', $_POST['add_ports']))
Components\Page::redirect('../../view.php?id='.$_POST['add_ports_node'].'&disp=add_port_fail&tab=allocation');

if(preg_match('/^[\d-,]+$/', $_POST['add_ports']))
Expand Down

0 comments on commit ae442d3

Please sign in to comment.