b4400a68e5
Baseline before backporting wp-data-optimizer v3.0.1-v3.4.6. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TbG1keQQ7XBa7qMQY16KCY
77 lines
1.8 KiB
PHP
77 lines
1.8 KiB
PHP
<?php
|
|
/**
|
|
* SEO adapter — `hivepress-seo`.
|
|
*
|
|
* The SEO addon is filter-based — it tweaks listing/vendor page titles,
|
|
* meta descriptions, OpenGraph tags. No models of its own, no postmeta
|
|
* additions beyond what HivePress core already manages.
|
|
*
|
|
* Adapter contributes only detection signal + readiness report. Nothing
|
|
* to anti-EAV.
|
|
*
|
|
* @package WP_Data_Optimizer
|
|
* @since 3.0.0
|
|
*/
|
|
|
|
if ( ! defined( 'ABSPATH' ) ) {
|
|
exit;
|
|
}
|
|
|
|
if ( ! class_exists( 'TMDO_HivePress_Seo_Adapter' ) ) {
|
|
|
|
/**
|
|
* SEO addon adapter (filter-based, no EAV surface).
|
|
*/
|
|
final class TMDO_HivePress_Seo_Adapter implements TMDO_HivePress_Adapter {
|
|
|
|
use TMDO_HivePress_Adapter_Trait;
|
|
|
|
/**
|
|
* Constructor — bind register hooks via inherited trait.
|
|
*/
|
|
public function __construct() {
|
|
$this->bind_anti_eav_hooks();
|
|
}
|
|
|
|
/** Adapter slug (matches wp.org plugin slug). */
|
|
public function plugin_slug(): string {
|
|
return 'hivepress-seo';
|
|
}
|
|
|
|
/** Class probed for addon presence. */
|
|
public function detection_class(): string {
|
|
return 'HivePress\\Seo\\Plugin';
|
|
}
|
|
|
|
/** Version constant probed for addon presence. */
|
|
public function detection_const(): string {
|
|
return 'HIVEPRESS_SEO_VERSION';
|
|
}
|
|
|
|
/** Minimum addon version supported. */
|
|
public function minimum_addon_version(): string {
|
|
return '1.0.0';
|
|
}
|
|
|
|
/**
|
|
* Doctor probe — filter-based addon has nothing to verify.
|
|
*
|
|
* @return array{ok:bool, message:string}
|
|
*/
|
|
public function doctor_check(): array {
|
|
return array(
|
|
'ok' => true,
|
|
'message' => 'hivepress-seo: filter-based addon, no anti-EAV surface',
|
|
);
|
|
}
|
|
|
|
/**
|
|
* 8-D self-score — perfect 10 (no EAV usage to optimize).
|
|
*/
|
|
public function suitability_score(): array {
|
|
return $this->compose_score( array() );
|
|
}
|
|
}
|
|
|
|
} // end if ( ! class_exists )
|