that have an array index other than 0
Since we don't enforce linear ordering of array keys on longer arrays, we
may as well not enforce it on single-element arrays either.
The freaky little Categoryfinder class was using different keys for its
arrays, which could cause a PHP notice and silent lookup failure when
only one ID was looked up.
* (bug 13436) Treat image captions correctly when they include option keywords
(like ending with "px" or starting with "upright")
* Trackback display formatting fixed
+* Don't die when single-element arrays are passed to SQL query constructors
+ that have an array index other than 0
=== API changes in 1.13 ===
throw new MWException( __METHOD__.': empty input' );
} elseif( count( $value ) == 1 ) {
// Special-case single values, as IN isn't terribly efficient
+ // Don't necessarily assume the single key is 0; we don't
+ // enforce linear numeric ordering on other arrays here.
+ $value = array_values( $value );
$list .= $field." = ".$this->addQuotes( $value[0] );
} else {
$list .= $field." IN (".$this->makeList($value).") ";