|
@@ -92,7 +92,7 @@ discard block |
|
|
block discarded – undo |
|
92
|
92
|
$this->db_saveItem(array_combine(array_keys($this->defaults), array_fill(0, count($this->defaults), null))); |
|
93
|
93
|
} |
|
94
|
94
|
|
|
95
|
|
- public function db_saveItem($item_list, $value = NULL) { |
|
|
95
|
+ public function db_saveItem($item_list, $value = null) { |
|
96
|
96
|
if(empty($item_list)) { |
|
97
|
97
|
return; |
|
98
|
98
|
} |
|
@@ -103,7 +103,7 @@ discard block |
|
|
block discarded – undo |
|
103
|
103
|
$qry = array(); |
|
104
|
104
|
foreach($item_list as $item_name => $item_value) { |
|
105
|
105
|
if($item_name) { |
|
106
|
|
- $item_value = SN::$db->db_escape($item_value === NULL ? $this->$item_name : $item_value); |
|
|
106
|
+ $item_value = SN::$db->db_escape($item_value === null ? $this->$item_name : $item_value); |
|
107
|
107
|
$item_name = SN::$db->db_escape($item_name); |
|
108
|
108
|
$qry[] = "('{$item_name}', '{$item_value}')"; |
|
109
|
109
|
} |
Please login to merge, or discard this patch.