PluginProbe
Yoast SEO – Advanced SEO with real-time guidance and built-in AI / trunk
Yoast SEO – Advanced SEO with real-time guidance and built-in AI vtrunk
28.5 28.4 28.3 28.2 28.1 28.0 27.9 27.8 27.7 27.6 27.5 trunk 18.0 18.1 18.2 18.3 18.4 18.4.1 18.5 18.5.1 18.6 18.7 18.8 18.9 19.0 All 129 releases
← All changes | src/bulk-editor/application/updates/meta-writer-interface.php +15 -1 28.1 → trunk View file →
@@ -35,11 +35,25 @@
35 35 /**
36 36 * Writes the focus keyphrase for a post. The focus keyphrase is channel-agnostic,
37 37 * so it does not depend on the update type.
38 38 *
39 + * Returns the sanitized value that was actually stored, so callers can detect
40 + * when the input was silently altered (e.g. HTML stripped by sanitize_text_field).
41 + *
39 42 * @param int $post_id The ID of the post.
40 43 * @param string $focus_keyphrase The focus keyphrase to write.
41 44 *
45 + * @return string The sanitized focus keyphrase that was persisted.
46 + */
47 + public function write_focus_keyphrase( int $post_id, string $focus_keyphrase ): string;
48 +
49 + /**
50 + * Writes a per-field score for a post.
51 + *
52 + * @param int $post_id The ID of the post.
53 + * @param string $key The score meta key (without prefix) to write.
54 + * @param int $score The 0-100 score to write.
55 + *
42 56 * @return void
43 57 */
44 - public function write_focus_keyphrase( int $post_id, string $focus_keyphrase ): void;
58 + public function write_score( int $post_id, string $key, int $score ): void;
45 59 }