PluginProbe
ThinkRank AI SEO – AI SEO Plugin for WordPress: Schema, XML Sitemaps, Meta Tags, Search Console & Local SEO / 2.10.0
ThinkRank AI SEO – AI SEO Plugin for WordPress: Schema, XML Sitemaps, Meta Tags, Search Console & Local SEO v2.10.0
2.11.0 2.10.0 2.9.0 2.8.0 2.7.0 2.6.0 2.5.0 2.4.0 2.3.0 2.2.0 2.1.1 2.1.0 2.0.2 2.0.1 2.0.0 1.32.0 1.31.0 1.30.0 1.29.0 1.28.0 1.27.0 1.26.0 1.25.0 trunk 1.0.0 All 52 releases
← All changes | includes/abilities/analysis/class-get-post-seo-checks.php +12 -2 1.25.0 → 2.10.0 View file →
@@ -12,8 +12,9 @@
12 12 use ThinkRank\Abilities\Ability_Base;
13 13 use ThinkRank\Admin\Metabox_Manager;
14 14 use ThinkRank\AI\SEOScoreCalculator;
15 15 use ThinkRank\Core\Database;
16 +use ThinkRank\SEO\Pattern_Resolver;
16 17
17 18 if ( ! defined( 'ABSPATH' ) ) {
18 19 exit; // Exit if accessed directly.
19 20 }
@@ -27,9 +28,9 @@
27 28 */
28 29 public function __construct() {
29 30 $this->id = 'thinkrank/get-post-seo-checks';
30 31 $this->label = __( 'Get ThinkRank Post SEO Checks', 'thinkrank' );
31 - $this->description = __( 'Run ThinkRank SEO score analysis for one or more posts, pages, or custom post type items.', 'thinkrank' );
32 + $this->description = __( 'Run ThinkRank SEO score analysis for one or more posts, pages, or custom post type items. Scores are not persisted; use bulk-analyze-and-save to score and store them.', 'thinkrank' );
32 33 }
33 34
34 35 /**
35 36 * {@inheritDoc}
@@ -115,9 +116,18 @@
115 116
116 117 foreach ( $post_ids as $post_id ) {
117 118 try {
118 119 $content = $calculator->analyze_post_content( $post_id );
119 - $score = $calculator->calculate_score( $content, $metabox->get_post_metadata( $post_id ) );
120 +
121 + // Override the raw per-post title/description with their effective
122 + // values (custom value, else the resolved Global pattern) so an
123 + // inherited title or description is scored as present — matching
124 + // the editor and frontend — instead of counting as missing.
125 + $metadata = $metabox->get_post_metadata( $post_id );
126 + $metadata['title'] = Pattern_Resolver::effective_title( $post_id );
127 + $metadata['description'] = Pattern_Resolver::effective_description( $post_id );
128 +
129 + $score = $calculator->calculate_score( $content, $metadata );
120 130
121 131 $data[] = [
122 132 'post_id' => $post_id,
123 133 'score' => $score,