FIXES on Bootstrap and Path classes

1. On bootstrap class, was added static declaration for registerClass() method
2. On Patch class was removed at top the loadClass('system') call, because this make a redeclaration error, in PHP ver 5.3.2x
   and it was moved into function that use that, now it is just loaded conditionally.
This commit is contained in:
Erik Amaru Ortiz
2014-01-15 12:16:46 -04:00
parent 7ca20324e7
commit 2ffd4e315f
2 changed files with 5 additions and 2 deletions

View File

@@ -30,7 +30,7 @@ class Bootstrap
return; return;
} }
public function registerClass($classname, $includeFile) public static function registerClass($classname, $includeFile)
{ {
BootStrap::$includeClassPaths[strtolower($classname)] = $includeFile; BootStrap::$includeClassPaths[strtolower($classname)] = $includeFile;
return; return;

View File

@@ -2,7 +2,6 @@
G::LoadClass("Task"); G::LoadClass("Task");
G::LoadClass("TaskUser"); G::LoadClass("TaskUser");
G::LoadClass("System");
/** /**
* class, helping to set some not desirable settings but necesary * class, helping to set some not desirable settings but necesary
@@ -26,6 +25,10 @@ class p11835 extends patch
*/ */
static public function isApplicable() static public function isApplicable()
{ {
if (! class_exists('System')) {
G::LoadClass("System");
}
patch::$isPathchable = false; patch::$isPathchable = false;
$con = Propel::getConnection("workflow"); $con = Propel::getConnection("workflow");
$stmt = $con->prepareStatement("describe TASK;"); $stmt = $con->prepareStatement("describe TASK;");