WordPress.org

Make WordPress Core


Ignore:
Timestamp:
10/29/2020 04:52:48 PM (3 months ago)
Author:
whyisjake
Message:

Embeds: Disable embeds on deactivated Multisite sites.

Props xknown, whyisjake, zieladam, peterwilsoncc.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/5.5/src/wp-includes/embed.php

    r48574 r49374  
    610610        $sites = get_sites( $qv );
    611611        $site  = reset( $sites );
     612
     613        // Do not allow embeds for deleted/archived/spam sites.
     614        if ( ! empty( $site->deleted ) || ! empty( $site->spam ) || ! empty( $site->archived ) ) {
     615            return false;
     616        }
    612617
    613618        if ( $site && get_current_blog_id() !== (int) $site->blog_id ) {
Note: See TracChangeset for help on using the changeset viewer.