making the name lowercase in the addDetector method so that it will be found in the is() method fixes #2622 with tests.

This commit is contained in:
dogmatic69 2012-02-28 16:05:24 +00:00
parent 677f0708dc
commit ac06880241
2 changed files with 6 additions and 0 deletions

View file

@ -516,6 +516,7 @@ class CakeRequest implements ArrayAccess {
* @return void
*/
public function addDetector($name, $options) {
$name = strtolower($name);
if (isset($this->_detectors[$name]) && isset($options['options'])) {
$options = Set::merge($this->_detectors[$name], $options);
}