-ClassLoader::getInstance()->loadClasses(sprintf("%s/%s/", FrameworkConfiguration::getInstance()->readConfig("application_path"), $application));
-
-// Include all classes
-ClassLoader::getInstance()->includeAllClasses();
+ClassLoader::getInstance()->scanClassPath(sprintf("%s/%s/", $cfg->getConfigEntry('application_path'), $cfg->getConfigEntry('app_name')));