BUG Fix reference to obsolete API (#59)

This commit is contained in:
Damian Mooyman 2016-10-28 16:50:09 +13:00 committed by Sam Minnée
parent a5738dbfd1
commit f2ba2f6717

View File

@ -429,7 +429,7 @@ class PostgreSQLDatabase extends Database
$tableName = $searchableColumn['table_name'];
$columnName = $searchableColumn['column_name'];
$className = DataObject::getSchema()->tableClass($tableName);
if (DataObject::singleton($className)->db('ShowInSearch')) {
if (DataObject::getSchema()->fieldSpec($className, 'ShowInSearch')) {
$conditions[] = array('"ShowInSearch"' => 1);
}