From 32e1a5dfc76abfee31d7b0e02ec1731467e48647 Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Sat, 16 Jul 2005 00:03:52 +0000 Subject: [PATCH] Revert 1.106, needless complication that duplicates existing functionality with harder to read syntax. Use array('user_id=user_name') to do the same, already used in existing code. --- includes/Database.php | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/includes/Database.php b/includes/Database.php index c4d90ca10b..98bf45eddf 100644 --- a/includes/Database.php +++ b/includes/Database.php @@ -967,15 +967,13 @@ class Database { } if ( $mode == LIST_AND && is_numeric( $field ) ) { $list .= "($value)"; - } elseif ( $mode == LIST_AND && is_array ($value) && $value[0] !== false ) { + } elseif ( $mode == LIST_AND && is_array ($value) ) { $list .= $field." IN (".$this->makeList($value).") "; - } elseif ( $mode == LIST_AND && is_array ($value) && $value[0] === false ) { - $list .= "$field = {$value[1]}"; } else { if ( $mode == LIST_AND || $mode == LIST_SET ) { $list .= $field.'='; } - $list .= ($mode == LIST_NAMES ? $value : $this->addQuotes( $value )); + $list .= ($mode==LIST_NAMES?$value:$this->addQuotes( $value )); } } return $list; -- 2.20.1