Make WordPress Core


Ignore:
Timestamp:
07/14/2014 07:00:24 PM (10 years ago)
Author:
ocean90
Message:

Customizer: Add meta capability customize which is mapped to edit_theme_options.

You can now allow users to access the Customizer, say for any user who can edit_posts, via map_meta_cap or user_has_cap filter. See ticket for examples.

props westonruter, nacin.
fixes #28605.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-customize-manager.php

    r29157 r29170  
    158158        show_admin_bar( false );
    159159
    160         if ( ! current_user_can( 'edit_theme_options' ) )
     160        if ( ! current_user_can( 'customize' ) ) {
    161161            $this->wp_die( -1 );
     162        }
    162163
    163164        $this->original_stylesheet = get_stylesheet();
Note: See TracChangeset for help on using the changeset viewer.