Making WordPress.org


Ignore:
Timestamp:
05/01/2020 04:47:37 AM (6 years ago)
Author:
dd32
Message:

Support Forums: Add the ability to flag topics as NSFW.

This supports both a checkbox, and for matching on a phrase within the title/url/tags.

Props Clorith, denisco.
Fixes #2018.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/support-forums/inc/class-hooks.php

    r9708 r9802  
    489489                                $robots = true;
    490490                        }
     491
     492                        // If topic is marked as NSFW.
     493                        $is_nsfw = get_post_meta( bbp_get_topic_id(), '_topic_is_nsfw', true );
     494
     495                        if ( $is_nsfw ) {
     496                                $robots = true;
     497                        }
    491498                }
    492499
Note: See TracChangeset for help on using the changeset viewer.