Make WordPress Core

Opened 17 years ago

Closed 12 years ago

Last modified 12 years ago

#9378 closed enhancement (wontfix)

Deprecate manage_category cap in favor of its object type's cap

Reported by: mastermind's profile mastermind Owned by:
Milestone: Priority: normal
Severity: normal Version: 2.7.1
Component: Taxonomy Keywords: close
Focuses: Cc:

Description

I encountered a problem in WordPress 2.7.1 $wp_roles->remove_cap('editor', 'manage_links'); doesn't remove that capability for the Editor role entirely, but it still displays the page "link categories", and you can perform actions on that page. This is because that page needs "manage_categories" instead of "manage_links".

I would propose to either require the manage_links capability for this page, or introduce a new capability (something as manage_link_categories for example).

Attachments (1)

9378.diff (840 bytes) - added by Denis-de-Bernardy 17 years ago.
against r11256

Download all attachments as: .zip

Change History (9)

#1 @Denis-de-Bernardy
17 years ago

  • Keywords has-patch 2nd-opinion added
  • Milestone changed from Unassigned to 2.8

Patch attached, but I'm itching between suggesting that this should also be the case for post categories and tags, for the sake of consistency, or suggesting that what's really needed is a different manage_* capacity for each taxonomy...

#2 @Denis-de-Bernardy
17 years ago

  • Keywords dev-feedback added

#3 @Denis-de-Bernardy
17 years ago

  • Keywords tested commit added

commit? wontfix?

@Denis-de-Bernardy
17 years ago

against r11256

#4 @westi
17 years ago

  • Keywords needs-patch added; has-patch tested commit 2nd-opinion dev-feedback removed
  • Milestone changed from 2.8 to 2.9

Just changing it in the menu won't help here.

As if I still have the manage_categories cap then I can go to the page by url and change things there as that checks that cap.

Moving to 2.9 for now.

We need to decide if we can have per-taxonomy caps to provide better flexibility here.

#5 @Denis-de-Bernardy
17 years ago

  • Component changed from Administration to Taxonomy
  • Milestone changed from 2.9 to Future Release
  • Summary changed from Removing cap 'manage_links' doesn't remove all link related capabilities to Deprecate manage_category cap in favor of its object type's cap
  • Type changed from defect (bug) to enhancement

Suggesting the following instead:

We deprecate the manage_category cap. For each taxonomy, we look at the applicable object type instead.

If use can edit that object type, he can edit the taxonomy.

#6 @kevinB
16 years ago

  • Cc kevinB added

#7 @chriscct7
12 years ago

  • Keywords close added; needs-patch removed
  • Resolution set to wontfix
  • Status changed from new to closed

Given we don't show the link manager anymore on new installs, since #21307, it doesn't seem to be a valid concern anymore.

#8 @DrewAPicture
12 years ago

  • Milestone Future Release deleted
Note: See TracTickets for help on using tickets.