From: Michael Wallner Date: Thu, 12 Mar 2015 13:49:46 +0000 (+0100) Subject: fix bug with expected class type X-Git-Tag: v1.1.0 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=079ca547531915b0ba0cb6829a89d9c7d4b93408;p=m6w6%2Fmerry fix bug with expected class type --- diff --git a/lib/merry/Container.php b/lib/merry/Container.php index 7f4d8fc..8a62866 100644 --- a/lib/merry/Container.php +++ b/lib/merry/Container.php @@ -68,7 +68,7 @@ class Container implements \ArrayAccess, \RecursiveIterator, \JsonSerializable /** * Apply one or mor modifier callbacks * @param mixed $modifier - * @return \merry\Config + * @return \merry\Container */ public function apply($modifier) { if (is_callable($modifier)) { @@ -111,7 +111,7 @@ class Container implements \ArrayAccess, \RecursiveIterator, \JsonSerializable * @ignore */ function __set($prop, $value) { - if (isset($value) && !is_scalar($value) && !($value instanceof Config)) { + if (isset($value) && !is_scalar($value) && !($value instanceof Container)) { $value = new static((array) $value); } if (!strlen($prop)) {