Maybe some detailed error will be desired when no database info found for the desired database in the xml file.
Instead
if ($this->m_DatabaseInfo[$DBName])
return $this->m_DatabaseInfo[$DBName];
if (!$DBName)
return $DatabaseInfo;
Maybe
if ($this->m_DatabaseInfo[$DBName]) {
return $this->m_DatabaseInfo[$DBName];
} else if (!$DBName) {
//This variable never exists!!
return $DatabaseInfo;
} else {
throw new Exception ("No database information found in the config file for database {$DBName}");
}