WordPress.org

Make WordPress Core

Changeset 45615


Ignore:
Timestamp:
07/09/2019 08:56:37 PM (4 months ago)
Author:
SergeyBiryukov
Message:

I18N: Move code out of translatable string in a _deprecated_argument() message in wp_stream_image(), wp_save_image_file(), and image_edit_apply_changes().

Props ramiy.
Fixes #47406.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/image-edit.php

    r45583 r45615  
    273273        return true;
    274274    } else {
    275         _deprecated_argument( __FUNCTION__, '3.5.0', __( '$image needs to be an WP_Image_Editor object' ) );
     275        /* translators: 1: $image, 2: WP_Image_Editor */
     276        _deprecated_argument( __FUNCTION__, '3.5.0', sprintf( __( '%1$s needs to be a %2$s object.' ), '$image', 'WP_Image_Editor' ) );
    276277
    277278        /**
     
    341342        return $image->save( $filename, $mime_type );
    342343    } else {
    343         _deprecated_argument( __FUNCTION__, '3.5.0', __( '$image needs to be an WP_Image_Editor object' ) );
     344        /* translators: 1: $image, 2: WP_Image_Editor */
     345        _deprecated_argument( __FUNCTION__, '3.5.0', sprintf( __( '%1$s needs to be a %2$s object.' ), '$image', 'WP_Image_Editor' ) );
    344346
    345347        /** This filter is documented in wp-admin/includes/image-edit.php */
     
    487489function image_edit_apply_changes( $image, $changes ) {
    488490    if ( is_resource( $image ) ) {
    489         _deprecated_argument( __FUNCTION__, '3.5.0', __( '$image needs to be an WP_Image_Editor object' ) );
     491        /* translators: 1: $image, 2: WP_Image_Editor */
     492        _deprecated_argument( __FUNCTION__, '3.5.0', sprintf( __( '%1$s needs to be a %2$s object.' ), '$image', 'WP_Image_Editor' ) );
    490493    }
    491494
Note: See TracChangeset for help on using the changeset viewer.