1
0
mirror of synced 2025-01-18 14:31:40 +03:00

class dependency fix

This commit is contained in:
doctrine 2006-05-30 18:43:36 +00:00
parent e1548625b8
commit 776c47f769
5 changed files with 10 additions and 9 deletions

View File

@ -226,7 +226,8 @@ final class Doctrine {
if(! self::$path)
self::$path = dirname(__FILE__);
$dir = dir(self::$path);
$path = self::$path.DIRECTORY_SEPARATOR."Doctrine";
$dir = dir($path);
$a = array();
while (false !== ($entry = $dir->read())) {
switch($entry):
@ -243,11 +244,11 @@ final class Doctrine {
case "DQL":
case "Sensei":
case "Iterator":
$a[] = self::$path.DIRECTORY_SEPARATOR.$entry;
$a[] = $path.DIRECTORY_SEPARATOR.$entry;
break;
default:
if(is_file(self::$path.DIRECTORY_SEPARATOR.$entry) && substr($entry,-4) == ".php") {
require_once($entry);
if(is_file($path.DIRECTORY_SEPARATOR.$entry) && substr($entry,-4) == ".php") {
require_once($path.DIRECTORY_SEPARATOR.$entry);
}
endswitch;
}

View File

@ -1,5 +1,5 @@
<?php
require_once(Doctrine::getPath().DIRECTORY_SEPARATOR."Exception.php");
Doctrine::autoload('Doctrine_Exception');
/**
* thrown when user defined Doctrine_Table is badly named
*/

View File

@ -1,5 +1,5 @@
<?php
require_once(Doctrine::getPath().DIRECTORY_SEPARATOR."Exception.php");
Doctrine::autoload('Doctrine_Exception');
/**
* thrown when Doctrine_Record is refreshed and the refreshed primary key doens't match the old one
*/

View File

@ -1,5 +1,5 @@
<?php
require_once(Doctrine::getPath().DIRECTORY_SEPARATOR."Exception.php");
Doctrine::autoload('Doctrine_Exception');
/**
* thrown when user tries to get the current
* session and there are no open sessions

View File

@ -1,5 +1,5 @@
<?php
require_once(Doctrine::getPath().DIRECTORY_SEPARATOR."Exception.php");
Doctrine::autoload('Doctrine_Exception');
/**
* thrown when user tries to initialize a new instance of Doctrine_Table,
* while there already exists an instance of that table