[pLog-svn] r7249 - plog/branches/lifetype-1.2/class/database/pdb/drivers
jondaley at devel.lifetype.net
jondaley at devel.lifetype.net
Wed Oct 14 01:37:34 EDT 2020
Author: jondaley
Date: 2020-10-14 01:37:34 -0400 (Wed, 14 Oct 2020)
New Revision: 7249
Modified:
plog/branches/lifetype-1.2/class/database/pdb/drivers/pdbdriverbase.class.php
plog/branches/lifetype-1.2/class/database/pdb/drivers/pdbmysqldriver.class.php
Log:
we already have _type, we don't need another parameter driverName. This fixes a bug in PHP7
Modified: plog/branches/lifetype-1.2/class/database/pdb/drivers/pdbdriverbase.class.php
===================================================================
--- plog/branches/lifetype-1.2/class/database/pdb/drivers/pdbdriverbase.class.php 2020-10-14 05:36:24 UTC (rev 7248)
+++ plog/branches/lifetype-1.2/class/database/pdb/drivers/pdbdriverbase.class.php 2020-10-14 05:37:34 UTC (rev 7249)
@@ -24,7 +24,7 @@
var $_debug = false;
var $_connected = false;
var $_opts;
-
+
/**
* Generates a new instance of the driver. Please use PDb::getDriver() instead
*
@@ -213,17 +213,14 @@
/**
* Load the correct data dictionary driver. Child classes should overwrite this method
* and provide the right driver name so that this method can be called without parameters.
- *
- * @param driverName the driver name.
- * @param A reference to the driver-specific PDbBaseDataDict object
*/
- function &getDriverDataDictionary( $driverName )
+ function getDriverDataDictionary()
{
- $dataDictPath = PLOG_CLASS_PATH."class/database/pdb/datadict/pdb".strtolower($driverName)."datadict.class.php";
+ $dataDictPath = PLOG_CLASS_PATH."class/database/pdb/datadict/pdb".strtolower($this->_type)."datadict.class.php";
// check if the driver exists at all
if( !is_readable( $dataDictPath )) {
- throw( new Exception( "Cannot load data dictionary for driver $driverName!" ));
+ throw( new Exception( "Cannot load data dictionary for driver ".$this->_type."!" ));
die();
}
@@ -231,12 +228,12 @@
lt_include( $dataDictPath );
- $className = "PDb{$driverName}DataDict";
+ $className = "PDb".$this->type."DataDict";
$class = new $className();
$class->dataProvider = $this;
$class->connection = &$this;
- $class->upperName = strtoupper($driverName);
+ $class->upperName = strtoupper($this->_type);
return( $class );
}
Modified: plog/branches/lifetype-1.2/class/database/pdb/drivers/pdbmysqldriver.class.php
===================================================================
--- plog/branches/lifetype-1.2/class/database/pdb/drivers/pdbmysqldriver.class.php 2020-10-14 05:36:24 UTC (rev 7248)
+++ plog/branches/lifetype-1.2/class/database/pdb/drivers/pdbmysqldriver.class.php 2020-10-14 05:37:34 UTC (rev 7249)
@@ -133,14 +133,6 @@
}
/**
- * @see PDbDriverBase::getDriverDataDictionary()
- */
- function getDriverDataDictionary()
- {
- return( PDbDriverBase::getDriverDataDictionary( 'mysql' ));
- }
-
- /**
* Returns true if the current database supports FULLTEXT searches. This is currently
* configured in the database configuration file, config/config.properties.php:
*
More information about the pLog-svn
mailing list