Implement __get() placeholder to prevent a flood of E_NOTICE

This commit is contained in:
Kijin Sung 2016-01-08 21:36:53 +09:00
parent b957bfebc5
commit 32fd2fb609

View file

@ -1945,6 +1945,19 @@ class Context
return $url[$ssl_mode][$domain_key];
}
/**
* Magic method to return null instead of throwing E_NOTICE when undefined properties are accessed
*
* We do not define a corresponding __set() because it does not work with assignment by reference.
*
* @param string $key
* @return null
*/
public function __get($key)
{
return null;
}
/**
* Set a context value with a key
*