[wp-trac] [WordPress Trac] #45423: Use custom capabilities for the block editor's reusable blocks.
WordPress Trac
noreply at wordpress.org
Mon Jan 21 15:37:30 UTC 2019
#45423: Use custom capabilities for the block editor's reusable blocks.
------------------------------------------+-----------------------
Reporter: peterwilsoncc | Owner: pento
Type: defect (bug) | Status: assigned
Priority: normal | Milestone: 5.2
Component: Role/Capability | Version: 5.0
Severity: normal | Resolution:
Keywords: needs-patch needs-unit-tests | Focuses:
------------------------------------------+-----------------------
Changes (by flixos90):
* keywords: has-patch has-unit-tests => needs-patch needs-unit-tests
* milestone: 5.1 => 5.2
Comment:
I recommend against moving forward with this approach. We haven't
introduced new primitive capabilities since WordPress 3.0, and that is for
a reason. Migrating databases like that should not be required and can
easily cause issues, specifically with larger multisites. There have been
numerous capabilities introduced since 3.0, but these have always used
either the `map_meta_cap` or `user_has_cap` filter, granting them
dynamically.
I think we should introduce these capabilities as dynamic capabilities
using the `user_has_cap` filter, making them what I have so far called
"fake-primitive" capabilities (only for the lack of a better word). See
#44468 for more information on that.
Since this ticket has been moved from 5.1 to "Future Release" before, it
seems to not be super-critical for 5.1. Let's tackle #44468 and this one
as an enhancement for 5.2, to have sufficient time for a proper
implementation. I'll move the two tickets to that milestone now, and I'm
happy to work on it. For the unit tests, this ticket is blocked by #44468.
If I was mistaken and this ticket is more critical, I suggest moving both
of them to 5.1.x.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/45423#comment:10>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list