Making WordPress.org


Ignore:
Timestamp:
04/01/2020 06:48:12 AM (7 years ago)
Author:
dd32
Message:

Plugin Directory: Switch the capability used for self-closing plugins.

These caps are exactly the same, but this makes more sense in the context.

See #1560.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/api/routes/class-plugin-self-close.php

    r9672 r9674  
    2525                                $plugin = Plugin_Directory::get_plugin_post( $request['plugin_slug'] );
    2626
    27                                 return current_user_can( 'plugin_add_committer', $plugin ) && 'publish' === $plugin->post_status;
     27                                return current_user_can( 'plugin_admin_edit', $plugin ) && 'publish' === $plugin->post_status;
    2828                        },
    2929                ] );
Note: See TracChangeset for help on using the changeset viewer.