[wp-trac] [WordPress Trac] #36803: ms-files.php: inconsistent behaviour for upload visibility on archived sites

WordPress Trac noreply at wordpress.org
Tue May 10 15:14:13 UTC 2016


#36803: ms-files.php: inconsistent behaviour for upload visibility on archived
sites
--------------------------+-----------------------------
 Reporter:  antwortzeit   |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:  4.5.2
 Severity:  normal        |   Keywords:
  Focuses:  multisite     |
--------------------------+-----------------------------
 Hey,

 i just ran into an odd issue on one of our clients Multisites. I archived
 the said site and – as you know – it remains accessible for network
 admins. The matching files however don't. I followed this down to ms-
 files.php::21ff.

 {{{#!php
 <?php

 if ( $current_blog->archived == '1' || $current_blog->spam == '1' ||
 $current_blog->deleted == '1' ) {
         status_header( 404 );
         die( '404 — File not found.' );
 }

 }}}

 You see that ms-files.php checks, if the blog is archived (or spam or
 deleted) and than throws out a 404. Shouldn't this include a check for
 network admin users to see the files? Or, if that's not desirable,
 couldn't we make this check accessible for filters?

 Thanks for the good work!

 Christian

--
Ticket URL: <https://core.trac.wordpress.org/ticket/36803>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list