From f7466f7b444706d2a0382c0b569bb0f7f65ab6da Mon Sep 17 00:00:00 2001 From: xue <> Date: Sat, 10 Dec 2005 18:11:10 +0000 Subject: Prado::using now will not include a file if the corresponding class is already defined. --- framework/core.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'framework') diff --git a/framework/core.php b/framework/core.php index efd091ad..b5aa701c 100644 --- a/framework/core.php +++ b/framework/core.php @@ -571,7 +571,8 @@ class PradoBase if(is_file($path)) { self::$_usings[$namespace]=$path; - require_once($path); + if(!class_exists(substr(strrchr($namespace,'.'),1),false)) + require_once($path); } else throw new TInvalidDataValueException('prado_using_invalid',$namespace); -- cgit v1.2.3