Making WordPress.org

Changeset 12698


Ignore:
Timestamp:
07/03/2023 07:06:04 PM (3 years ago)
Author:
coffee2code
Message:

Photo Directory, Photo: Consider flagged photos as being controversial.

See #7119.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/photo-directory/inc/photo.php

    r12690 r12698  
    10011001     * This only applies for unpublished photos that also meet one of these
    10021002     * criteria:
     1003     * - Post status is 'flagged'
    10031004     * - Flagged by Vision as being "possible" or more likely in any criteria category
    10041005     *
     
    10191020        }
    10201021
     1022        $post_status = get_post_status( $post );
     1023
    10211024        // Not controversial if it has been published.
    1022         if ( 'publish' === get_post_status( $post ) ) {
    1023             return false;
     1025        if ( 'publish' === $post_status ) {
     1026            return false;
     1027        }
     1028
     1029        // Controversial if photo is outright flagged.
     1030        if ( Flagged::get_post_status() === $post_status ) {
     1031            return true;
    10241032        }
    10251033
Note: See TracChangeset for help on using the changeset viewer.