diff --git a/includes/class-tmdo-hivepress-entity-groups.php b/includes/class-tmdo-hivepress-entity-groups.php index eed41ea..27d41ee 100644 --- a/includes/class-tmdo-hivepress-entity-groups.php +++ b/includes/class-tmdo-hivepress-entity-groups.php @@ -262,10 +262,12 @@ final class TMDO_HivePress_Entity_Groups { // Filtered and sorted on by HivePress search. Declared as indexes // (added in place) rather than `searchable`, which would change // the schema hash and rebuild a table that may hold aeav_only data. - 'indexes' => array( + // Only with core 1.3.0+ (ddl_allowed()): older cores run the ALTER + // inside whatever request comes first, a visitor's included. + 'indexes' => method_exists( 'TMDO_Schema_Manager', 'ddl_allowed' ) ? array( 'hourly_rate' => array( 'hp_hourly_rate' ), 'rating_count' => array( 'hp_rating_count' ), - ), + ) : array(), ) ); }