fix(i18n): add translators comment for sprintf placeholder in rest-api

WordPress PHPCS requires a translators comment before sprintf() calls
that wrap __() with %s placeholders.

Agent-Session: claude/adopt-ci-20260616
This commit is contained in:
peptiderepo
2026-06-16 13:55:38 +00:00
parent a60ca84dc0
commit 3b4e3f0450

View File

@@ -104,6 +104,7 @@ class Peptide_News_Rest_API {
if ( ! preg_match( '/^\\d{4}-\\d{2}-\\d{2}$/', $value ) ) {
return new WP_Error(
'rest_invalid_date',
/* translators: %s: REST API parameter name */
sprintf( __( 'Invalid date format for %s. Expected Y-m-d.', 'peptide-news' ), $param ),
array( 'status' => 400 )
);