diff --git a/cake/dispatcher.php b/cake/dispatcher.php index 7ede6203a..6d590cd9b 100644 --- a/cake/dispatcher.php +++ b/cake/dispatcher.php @@ -620,6 +620,7 @@ class Dispatcher extends Object { } App::import('View', 'Media', false); + $controller = null; $Media = new MediaView($controller); if (isset($Media->mimeType[$ext])) { $contentType = $Media->mimeType[$ext]; diff --git a/cake/libs/view/media.php b/cake/libs/view/media.php index e85924b64..93c394a38 100644 --- a/cake/libs/view/media.php +++ b/cake/libs/view/media.php @@ -95,7 +95,7 @@ class MediaView extends View { * * @param object $controller */ - function __construct(&$controller = null) { + function __construct(&$controller) { parent::__construct($controller); }