Changeset 4112
- Timestamp:
- 09/20/2016 07:10:35 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/wordpress.org/public_html/wp-content/plugins/rosetta/inc/site/class-locale-team.php
r4108 r4112 61 61 add_filter( 'user_has_cap', [ $this, 'extend_editors_capabilities' ], 10, 4 ); 62 62 add_filter( 'editable_roles', [ $this, 'remove_administrator_from_editable_roles' ] ); 63 add_action( 'customize_register', [ $this, 'allow_editors_to_change_site_title_in_customizer' ], 20 ); 63 64 } 64 65 … … 99 100 return $roles; 100 101 } 102 103 /** 104 * Allows users with the 'edit_theme_options' capability to change the site title 105 * in the customizer. 106 * 107 * @param WP_Customize_Manager $wp_customize The customizer object. 108 */ 109 public function allow_editors_to_change_site_title_in_customizer( $wp_customize ) { 110 $wp_customize->get_setting( 'blogname' )->capability = 'edit_theme_options'; 111 $wp_customize->get_setting( 'blogdescription' )->capability = 'edit_theme_options'; 112 } 101 113 }
Note: See TracChangeset
for help on using the changeset viewer.