From 2aed9e476f51d5e1d3331a9709e3999b8b9cf899 Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Thu, 15 Apr 2010 14:56:37 +0000 Subject: [PATCH] Fix copy/paste error to get address merging working --- etemplate/inc/class.so_sql_cf.inc.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/etemplate/inc/class.so_sql_cf.inc.php b/etemplate/inc/class.so_sql_cf.inc.php index 62d06df949..efabb06821 100644 --- a/etemplate/inc/class.so_sql_cf.inc.php +++ b/etemplate/inc/class.so_sql_cf.inc.php @@ -446,14 +446,14 @@ class so_sql_cf extends so_sql unset($criteria[$this->autoinc_id]); } // replace ambiguous column with (an exact match of) table_name.column - elseif (is_string($name) && $val!=null && in_array($name, $this->db_cols)) + foreach($criteria as $name => $val) { $extra_columns = $this->db->get_table_definitions($app, $this->extra_table); if($extra_columns['fd'][array_search($name, $this->db_cols)]) { - $filter[] = $this->db->expression($this->table_name,$this->table_name.'.',array( + $criteria[] = $this->db->expression($this->table_name,$this->table_name.'.',array( array_search($name, $this->db_cols) => $val, )); - unset($filter[$name]); + unset($criteria[$name]); } } }