Make WordPress Core

Ticket #9292: 9292.diff

File 9292.diff, 585 bytes (added by ionfish, 16 years ago)
  • wp-includes/wp-db.php

     
    503503                $args = func_get_args();
    504504                $query = array_shift($args);
    505505                // If args were passed as an array, move them up
    506                 if ( is_array($args[0]) )
     506                if ( isset($args[0]) && is_array($args[0]) )
    507507                        $args = $args[0];
    508508                $query = str_replace("'%s'", '%s', $query); // in case someone mistakenly already singlequoted it
    509509                $query = str_replace('"%s"', '%s', $query); // doublequote unquoting