Avoid duplicate testing if array element is set.

This commit is contained in:
Michal Čihař
2010-04-22 20:22:53 +02:00
parent 20925728e7
commit 9978dddea2

View File

@@ -290,7 +290,6 @@ if ((isset($_REQUEST['submit_connect']))) {
*/ */
if (isset($update_array[$i])) { if (isset($update_array[$i])) {
if (isset($update_array[$i][0][$matching_tables_keys[$i][0]])) { if (isset($update_array[$i][0][$matching_tables_keys[$i][0]])) {
if (isset($update_array[$i])) {
$num_of_updates = sizeof($update_array[$i]); $num_of_updates = sizeof($update_array[$i]);
} else { } else {
$num_of_updates = 0; $num_of_updates = 0;
@@ -298,13 +297,11 @@ if ((isset($_REQUEST['submit_connect']))) {
} else { } else {
$num_of_updates = 0; $num_of_updates = 0;
} }
}
/** /**
* Calculating the number of insertions for each matching table * Calculating the number of insertions for each matching table
*/ */
if (isset($insert_array[$i])) { if (isset($insert_array[$i])) {
if (isset($insert_array[$i][0][$matching_tables_keys[$i][0]])) { if (isset($insert_array[$i][0][$matching_tables_keys[$i][0]])) {
if (isset($insert_array[$i])) {
$num_of_insertions = sizeof($insert_array[$i]); $num_of_insertions = sizeof($insert_array[$i]);
} else { } else {
$num_of_insertions = 0; $num_of_insertions = 0;
@@ -312,7 +309,6 @@ if ((isset($_REQUEST['submit_connect']))) {
} else { } else {
$num_of_insertions = 0; $num_of_insertions = 0;
} }
}
/** /**
* Displays the name of the matching table * Displays the name of the matching table
*/ */