Skip to content

Commit

Permalink
Fixed bug #018174: Slow mysql query: eZMBPAEX select *.
Browse files Browse the repository at this point in the history
Deprecated and removed call to eZPaEx::schemaCreated() as eZPublish
will always trigger an error when querying a non-existent table
  • Loading branch information
lolautruche committed Mar 23, 2011
1 parent aea5125 commit 9df085b
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 14 deletions.
10 changes: 7 additions & 3 deletions classes/ezpaex.php
Expand Up @@ -589,9 +589,13 @@ static function fetchUpdateChildrenPendingList( $asObject = true )
}

/**
* Checks if the database schema has been created, in order to prevent the
* datatype from being registered if it hasn't
**/
* DEPRECATED since querying a non-existent table will always trigger a fatal error
*
* Checks if the database schema has been created, in order to prevent the
* datatype from being registered if it hasn't
*
* @deprecated
*/
static function schemaCreated()
{
$db = eZDB::instance();
Expand Down
13 changes: 2 additions & 11 deletions datatypes/ezpaex/ezpaextype.php
Expand Up @@ -350,16 +350,7 @@ function isIndexable()
{
return true;
}

}

if ( eZPaEx::schemaCreated() )
{
eZDataType::register( ezpaextype::DATA_TYPE_STRING, "ezpaextype" );
}
else
{
eZDebug::writeError( "The database schema for ezmbpaex hasn't been imported to the database.", 'ezpaextype' );
}

?>
eZDataType::register( ezpaextype::DATA_TYPE_STRING, "ezpaextype" );
?>

0 comments on commit 9df085b

Please sign in to comment.