Making WordPress.org

Changeset 5473


Ignore:
Timestamp:
05/04/2017 03:14:23 AM (10 years ago)
Author:
dd32
Message:

Plugin Directory: API: Fix a typo preventing the screenshot captions being returned.

Fixes #2810

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/api/routes/class-plugin.php

    r5204 r5473  
    142142                        $src = Template::get_asset_url( $post, $image );
    143143                        $caption = '';
    144                         if ( $descriptions && !empty( $description[ (int)$image['resolution'] ] ) ) {
    145                                 $caption = $description[ (int)$image['resolution'] ];
     144                        if ( $descriptions && !empty( $descriptions[ (int)$image['resolution'] ] ) ) {
     145                                $caption = $descriptions[ (int)$image['resolution'] ];
    146146                                $caption = Plugin_I18n::instance()->translate( 'screenshot-' . $image['resolution'], $caption, [ 'post_id' => $post->ID ] );
    147147                        }
Note: See TracChangeset for help on using the changeset viewer.