From fbd1283d6ea95a1916b78fb0f2f59c20db3a7966 Mon Sep 17 00:00:00 2001 From: Nick Liu Date: Fri, 2 Feb 2018 08:24:31 -0600 Subject: [PATCH] e_pref::update() accepts existing keys with NULL e_pref::update() will now update keys' values where the keys have a value of NULL Fixes: #3021 --- e107_handlers/pref_class.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/e107_handlers/pref_class.php b/e107_handlers/pref_class.php index 71b1cee00..57549820a 100644 --- a/e107_handlers/pref_class.php +++ b/e107_handlers/pref_class.php @@ -240,7 +240,7 @@ class e_pref extends e_front_model { return $this; } - if(isset($this->_data[$pref_name])) + if(array_key_exists($pref_name, $this->_data)) { if($this->_data[$pref_name] != $value) $this->data_has_changed = true; $this->_data[$pref_name] = $value;