#16295 closed enhancement (wontfix)
Authors can see files uploaded by other authors in Media Library
| Reported by: |
|
Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | Media | Version: | 3.0.4 |
| Severity: | normal | Keywords: | |
| Cc: |
Description
Hi,
I build a site for many users (but not multisite) and find that in the media library (wp-admin/upload.php) the 'author'-user (not admin) can see the list of all files uploaded by other authors.
It is not a problem in case users are close friends and the list is not large but it's unsuitable when users are competitors, also hundreds of other's pictures is a bother.
Yes, current_user_can() prevents from editing or deleting pictures uploaded by other users but there is no need even see them here (or maybe make this feature switchable)?
Attachments (1)
Change History (10)
comment:1
in reply to:
↑ description
solarissmoke — 2 years ago
- Keywords dev-feedback added; media upload capabilities removed
This would be pretty easy to do with a filter.
I wouldn't mind the suggestion of a 'Mine' link as it occurs for posts, but it seems like an edge case. (As it is, you need to be less than an Editor to be able to see that link for posts -- which perhaps is another story.)
if ( is_admin() )
add_action( 'request', 'nacin_hide_uploads_from_other_users' );
function nacin_hide_uploads_from_other_users( $request ) {
global $pagenow;
if ( 'upload.php' == $pagenow && ! current_user_can( 'edit_others_posts' ) )
$request['author'] = get_current_user_id();
return $request;
}
comment:4
solarissmoke — 2 years ago
- Keywords has-patch added
Here's a patch that adds a filter for author.
When I said filter, I meant via a plugin. I don't see a need for a new UI dropdown. We don't even have an author dropdown on edit.php, where it would be more important. Limiting attachments by author is rather edge, certainly more so than posts.
comment:6
solarissmoke — 2 years ago
- Keywords dev-feedback has-patch removed
Okay fair enough - guess this can be closed then?
comment:8
solarissmoke — 2 years ago
- Resolution set to wontfix
- Status changed from new to closed

I think many sites do like users to be able to share media. However it might be a good idea to add an option to filter the list by author.