Make WordPress Core


Ignore:
Timestamp:
06/08/2020 09:25:46 PM (5 years ago)
Author:
desrosj
Message:

Coding Standards: PHP short ternary operator syntax is not allowed.

WPCS 2.2.0 added a sniff for detecting short ternary operator syntax, which is not allowed per the Core handbook.

Follow up of [47927].
Fixes #50258.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-themes-controller.php

    r47921 r47929  
    145145        if ( rest_is_field_included( 'screenshot', $fields ) ) {
    146146            // Using $theme->get_screenshot() with no args to get absolute URL.
    147             $data['screenshot'] = $theme->get_screenshot() ?: '';
     147            $data['screenshot'] = $theme->get_screenshot() ? $theme->get_screenshot() : '';
    148148        }
    149149
Note: See TracChangeset for help on using the changeset viewer.