Opened 11 months ago

Closed 10 months ago

Last modified 9 months ago

#7119 closed task (blessed) (fixed)

Separate out controversial photo submissions to allow for international moderation

Reported by: coffee2code's profile coffee2code Owned by: coffee2code's profile coffee2code
Milestone: Priority: normal
Component: Photo Directory Keywords:


Not all countries allow people to legally view certain types of photos (which the site classifies as controversial), even if unintentional. Allowing for, and protecting, international moderators without getting into the weeds of every country's laws requires that we take every precaution we can to restrict their access to controversial photos.

To accommodate this, there should be a number of changes, among which include:

  1. Introduce the "Photo Admin" role. This role will have full access to all photos, including those flagged as controversial. Only those moderators who are in vetted jurisdictions that allow them to view controversial photos, and who agree to potentially being exposed to such images, can be assigned this role.
  2. Introduce a custom post status for photos called "flagged". This will only be accessible by Photo Admins. Photos categorized as such will consist of:
    1. Photos that are auto-flagged by our submission handling code as being controversial based on the Vision API analysis.
    2. Photos that somehow haven't been processed by Vision API (and thus we initially don't know if the photo could be controversial or not).
    3. Photos explicitly set as flagged by any moderator or admin.
  3. Flagged photos can be unflagged by admins and put back into the queue for general moderation. A record of the unflagging should be made and presented so it's clear to moderators that the photo was unflagged (to prevent it from being manually flagged again).
  4. Update admin UI in various places for all moderators and admins to account for flagged photos:
    1. In the 'Author' post listing column, add a count of author's currently flagged photos. If the current user is an admin, link the count to a listing of those photos.
    2. In the 'Photo Contributor' metabox, add a count of author's currently flagged photos. If the current user is an admin, link the count to a listing of those photos.
    3. Allow flagged post status to be assigned or changed via Quick Edit and Bulk Edit.
    4. Once unflagged, stop displaying the photo content flags under photos in the Photo column (presumably the unflagging admin has deemed them of no concern).
    5. Prevent direct access by moderators to listings of flagged photos or to editing/viewing anything related to a flagged photo.
    6. Show admin notice when editing submissions that have been flagged or unflagged indicating who or what flagged/unflagged the photo.
  5. Update admin UI in various places for photo admins:
    1. Add an admin menu shortcut link 'Flagged' under 'Photos', much like the existing 'Queue' link. Also add a count indicator next to it with the total number of flagged photos, if there are any.
    2. Ensure flagged photos visually stand out
      1. Use a different background color in post listings.
      2. Show a "Flagged" post state indicator when listed amongst posts of other post statuses.

Change History (23)

#1 @coffee2code
11 months ago

In 12687:

Moderation: Add Photo Admin role.

See #7119.

#2 @coffee2code
11 months ago

In 12692:

Photo Directory, Flagged: Add 'flagged' post status for photos.

  • Only accessible to Admins and Photo Admins.
  • Registers 'flagged' post status.
  • Adds 'Flagged' admin submenu link under 'Photos'.
  • Adds post state indicator, if applicable.
  • Allows post status to be assigned via quick edit and bulk edit.
  • Adds count of user's flagged photos in 'Author' column.
  • Prevents unauthorized direct access to flagged photos and their listing.

See #7119.

#3 @coffee2code
11 months ago

In 12693:

Photo Directory, Moderation: Use getter for capability for flagged photos.

See #7119.

#4 @coffee2code
11 months ago

In 12694:

Photo Directory, Admin: Use light red/pink background colors for post listing rows for flagged photos.

See #7119.

#5 @coffee2code
11 months ago

In 12695:

Photo Directory, User: Add count_flagged_photos() to obtain count of user's flagged photos.

See #7119.

#6 @coffee2code
11 months ago

In 12697:

Photo Directory, Admin: Add count of flagged photos to Photo Contributor metabox.

See #7119.

#7 @coffee2code
11 months ago

In 12698:

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

See #7119.

#8 @coffee2code
11 months ago

In 12699:

Photo Directory, Flagged: Record the fact a photo gets unflagged, and by whom.

Also adds functions to determine if a photo was flagged/unflagged and each by whom.

See #7119.

#9 @coffee2code
11 months ago

In 12700:

Photo Directory, Admin: Display an admin notice on post edit pages to indicate when manually flagged or unflagged

This helps convey that a Photo Admin reviewed the photo and ascertained it wasn't controversial in nature, or who flagged a photo so a follow-up can be made if necessary.

See #7119.

#10 @coffee2code
11 months ago

In 12702:

Photo Directory, Photo: Don't consider unflagged photos as being controversial, despite any other indicators.

See #7119.

#11 @coffee2code
11 months ago

In 12703:

Photo Directory, Moderation: Show flags in Photo column for other post statuses as well.

See #7119.

#12 @coffee2code
11 months ago

In 12704:

Photo Directory, Moderation: Don't show Photo column flags for unflagged photos.

The presumption being that an admin has reviewed and dismissed the auto-assigned content flags.

See #7119.

#13 @coffee2code
11 months ago

In 12705:

Photo Directory, Flagged: Automatically flag submissions that seem controversial based on Vision API's moderation assessment.

See #7119.

#14 @coffee2code
11 months ago

In 12706:

Photo Directory, Admin: Properly report when a photo was automatically flagged versus manually flagged.

See #7119.

#15 @coffee2code
11 months ago

In 12707:

Photo Directory, Admin: Prevent moderators from accessing media library.

See #7119.

#16 @coffee2code
10 months ago

In 12725:

Photo Directory, Flagged: Treat flagged photos as pending.

See #7119.

#17 @coffee2code
10 months ago

In 12726:

Photo Directory, User: Update get_pending_photos() to account for all pending post statuses.

See #7119.

#18 @coffee2code
10 months ago

In 12727:

Photo Directory, User: Count 'flagged' photos towards submission count.

Also, reduce redundancy by using count_pending_photos().

See #7119.

#19 @coffee2code
10 months ago

In 12728:

Photo Directory, Moderation: Include flagged photos in Awaiting Moderation table.

See #7119.

#20 @coffee2code
10 months ago

In 12729:

Photo Directory, Moderation: Allow flags to be shown for other pending post statuses.

See #7119.

#21 @coffee2code
10 months ago

  • Resolution set to fixed
  • Status changed from assigned to closed

I feel this has been fully implemented at this point. Anything further should be considered a bug or enhancement.

This ticket was mentioned in Slack in #meta by courtneyengle. View the logs.

10 months ago

#23 @coffee2code
9 months ago

In 12870:

Photo Directory, Flagged: Show a count of flagged photos to moderators who otherwise wouldn't know about flagged photos.

See #7119.

Note: See TracTickets for help on using tickets.