Merge "Preload styles for 'jquery.tablesorter'"
[lhc/web/wiklou.git] / includes / db / DatabaseOracle.php
index 6d921b9..6af6de5 100644 (file)
@@ -390,13 +390,12 @@ class DatabaseOracle extends Database {
                foreach ( $a as &$row ) {
                        $this->insertOneRow( $table, $row, $fname );
                }
-               $retVal = true;
 
                if ( in_array( 'IGNORE', $options ) ) {
                        $this->ignoreDupValOnIndex = false;
                }
 
-               return $retVal;
+               return true;
        }
 
        private function fieldBindStatement( $table, $col, &$val, $includeCol = false ) {
@@ -580,19 +579,17 @@ class DatabaseOracle extends Database {
                        $this->ignoreDupValOnIndex = true;
                }
 
-               $retval = $this->query( $sql, $fname );
+               $this->query( $sql, $fname );
 
                if ( in_array( 'IGNORE', $insertOptions ) ) {
                        $this->ignoreDupValOnIndex = false;
                }
-
-               return $retval;
        }
 
        public function upsert( $table, array $rows, array $uniqueIndexes, array $set,
                $fname = __METHOD__
        ) {
-               if ( !count( $rows ) ) {
+               if ( $rows === [] ) {
                        return true; // nothing to do
                }
 
@@ -975,7 +972,7 @@ class DatabaseOracle extends Database {
                        if ( $sl < 0 ) {
                                continue;
                        }
-                       if ( '-' == $line[0] && '-' == $line[1] ) {
+                       if ( $line[0] == '-' && $line[1] == '-' ) {
                                continue;
                        }
 
@@ -989,7 +986,7 @@ class DatabaseOracle extends Database {
                                        $dollarquote = true;
                                }
                        } elseif ( !$dollarquote ) {
-                               if ( ';' == $line[$sl] && ( $sl < 2 || ';' != $line[$sl - 1] ) ) {
+                               if ( $line[$sl] == ';' && ( $sl < 2 || $line[$sl - 1] != ';' ) ) {
                                        $done = true;
                                        $line = substr( $line, 0, $sl );
                                }
@@ -1020,7 +1017,7 @@ class DatabaseOracle extends Database {
                                                call_user_func( $resultCallback, $res, $this );
                                        }
 
-                                       if ( false === $res ) {
+                                       if ( $res === false ) {
                                                $err = $this->lastError();
 
                                                return "Query \"{$cmd}\" failed with error code \"$err\".\n";