From b09056e13148353520ca8e2279a7db93a0308799 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Tue, 23 Jun 2020 22:29:00 +0000 Subject: [PATCH] I18N: Include placeholder in translator comments in `wp_get_auto_update_message()`. See #50436, #50052. git-svn-id: https://develop.svn.wordpress.org/trunk@48148 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/update.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/wp-admin/includes/update.php b/src/wp-admin/includes/update.php index 56140ead38..55630bdc5b 100644 --- a/src/wp-admin/includes/update.php +++ b/src/wp-admin/includes/update.php @@ -982,7 +982,7 @@ function wp_is_auto_update_enabled_for_type( $type ) { function wp_get_auto_update_message() { $next_update_time = wp_next_scheduled( 'wp_version_check' ); - // Check if event exists. + // Check if the event exists. if ( false === $next_update_time ) { $message = __( 'Auto-update update not scheduled. There may be a problem with WP-Cron.' ); } else { @@ -990,15 +990,16 @@ function wp_get_auto_update_message() { // See if cron is overdue. $overdue = ( time() - $next_update_time ) > 0; + if ( $overdue ) { $message = sprintf( - /* translators: Duration that WP-Cron has been overdue. */ + /* translators: %s: Duration that WP-Cron has been overdue. */ __( 'Auto-update update overdue by %s. There may be a problem with WP-Cron.' ), $time_to_next_update ); } else { $message = sprintf( - /* translators: Time until the next update. */ + /* translators: %s: Time until the next update. */ __( 'Auto-update update scheduled in %s.' ), $time_to_next_update );