mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-12 12:50:28 +00:00
I18N: Add missing translator comment in WP_Upgrader::generic_strings().
This resolves a WPCS warning: > A gettext call containing placeholders was found, but was not accompanied by a "translators:" comment on the line above to clarify the meaning of the placeholders. Includes moving `wp-content` out of the translatable string in a similar message in `_wp_delete_all_temp_backups()`. Follow-up to [55720], [56117]. Props jrf. See #58831. git-svn-id: https://develop.svn.wordpress.org/trunk@56276 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -189,6 +189,7 @@ class WP_Upgrader {
|
||||
$this->strings['fs_unavailable'] = __( 'Could not access filesystem.' );
|
||||
$this->strings['fs_error'] = __( 'Filesystem error.' );
|
||||
$this->strings['fs_no_root_dir'] = __( 'Unable to locate WordPress root directory.' );
|
||||
/* translators: %s: Directory name. */
|
||||
$this->strings['fs_no_content_dir'] = sprintf( __( 'Unable to locate WordPress content directory (%s).' ), 'wp-content' );
|
||||
$this->strings['fs_no_plugins_dir'] = __( 'Unable to locate WordPress plugin directory.' );
|
||||
$this->strings['fs_no_themes_dir'] = __( 'Unable to locate WordPress theme directory.' );
|
||||
|
||||
@@ -1119,7 +1119,11 @@ function _wp_delete_all_temp_backups() {
|
||||
}
|
||||
|
||||
if ( ! $wp_filesystem->wp_content_dir() ) {
|
||||
return new WP_Error( 'fs_no_content_dir', __( 'Unable to locate WordPress content directory (wp-content).' ) );
|
||||
return new WP_Error(
|
||||
'fs_no_content_dir',
|
||||
/* translators: %s: Directory name. */
|
||||
sprintf( __( 'Unable to locate WordPress content directory (%s).' ), 'wp-content' )
|
||||
);
|
||||
}
|
||||
|
||||
$temp_backup_dir = $wp_filesystem->wp_content_dir() . 'upgrade-temp-backup/';
|
||||
|
||||
Reference in New Issue
Block a user