diff --git a/src/Ratchet/Traits/DynamicPropertiesTrait.php b/src/Ratchet/Traits/DynamicPropertiesTrait.php index 5ebeac47..e470c93c 100644 --- a/src/Ratchet/Traits/DynamicPropertiesTrait.php +++ b/src/Ratchet/Traits/DynamicPropertiesTrait.php @@ -20,9 +20,7 @@ trait DynamicPropertiesTrait * @return void */ public function __set($key, $value) { - if (property_exists($this, $key)) { - $this->_dynamic_properties[$key] = $value; - } + $this->_dynamic_properties[$key] = $value; } /** @@ -46,4 +44,8 @@ public function __get($key) { public function __isset($key) { return isset($this->_dynamic_properties[$key]); } + + public function __unset($key) { + unset($this->_dynamic_properties[$key]); + } }