cakephp/cakephp — pull request #4182 by dereuromark (2014-08-06 20:55:32+00:00)
Title: Fix cookie reading.

As per IRC this issue has been reported while trying to write and read cookies:

> Catchable fatal error: Argument 1 passed to Hash::get() must be an array, string given, called in /var/www/html/stage/lib/Cake/Controller/Component/CookieComponent.php on line 286 and defined in /var/www/html/stage/lib/Cake/Utility/Hash.php on line 43

So we should check on is_array() first, before trying to use Hash::merge() on it to avoid the fatal error.

Any idea about a test case, though?