From c35c14ff39912cdb950fc800b32ef0e1fcbee22c Mon Sep 17 00:00:00 2001 From: gwoo Date: Fri, 18 May 2007 15:02:34 +0000 Subject: [PATCH] adding check for dispatcher class in requestAction git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@5116 3807eeeb-6ff5-0310-8944-8be069107fe0 --- cake/libs/object.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cake/libs/object.php b/cake/libs/object.php index 3f8d2571d..beccedd0f 100644 --- a/cake/libs/object.php +++ b/cake/libs/object.php @@ -83,6 +83,9 @@ class Object { */ function requestAction($url, $extra = array()) { if (!empty($url)) { + if(!class_exists('dispatcher')) { + require CAKE . 'dispatcher.php'; + } $dispatcher =& new Dispatcher(); if(isset($this->plugin)){ $extra['plugin'] = $this->plugin; @@ -136,7 +139,7 @@ class Object { * Allows setting of multiple properties of the object in a single line of code. * * @access public - * @param array $properties An associative array containing AuthComponent + * @param array $properties An associative array containing * properties and corresponding values. * @return void */