Opened 7 years ago
#41674 new enhancement
More granular capabilities for restoring and permanently deleting trashed posts
Reported by: | johnbillion | Owned by: | |
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | normal | Version: | |
Component: | Posts, Post Types | Keywords: | needs-patch needs-unit-tests granular-capabilities |
Focuses: | Cc: |
Description
Currently the user capability required for restoring a trashed post or permanently deleting a trashed post is delete_post
, which maps to delete_posts
. There should be a separate capability for each of these actions.
Suggestion:
restore_trashed_post
which maps torestore_trashed_posts
which maps todelete_posts
.delete_trashed_post
which maps todelete_trashed_posts
which maps todelete_posts
.
Emptying the trash should use the delete_trashed_posts
capability.
This allows for more granular control over which users can or cannot restore or permanently delete posts.
Note: See
TracTickets for help on using
tickets.