awesomemotive / WP-Mail-SMTP

The most popular WordPress SMTP and PHP Mailer plugin. Trusted by over 3 million sites.
https://wordpress.org/plugins/wp-mail-smtp/
GNU General Public License v3.0
55 stars 35 forks source link

Management of capabilities #126

Closed Inovagora closed 10 months ago

Inovagora commented 1 year ago

Hello,

Thanks for this plugin!

We have a specific configuration concerning the management of our users capabilities. To have access to the settings of this plugin, it is necessary to have the capability "manage_options", but our users do not have this right.

Would you be able to add a hook to modify the right to access these settings?

Here is an example of what I'd like to see regarding this request.

Thank you very much.

Screenshots

File src/Admin/Area.php, L282 image

alexander-sakal commented 1 year ago

Hello @Inovagora

Thank you for opening this issue!

We'll try to implement it in one of our future updates.

Inovagora commented 11 months ago

Hello @alexander-sakal, Do you think you'll be able to implement this feature soon?

alexander-sakal commented 10 months ago

Hello @Inovagora. Yes, we are planning to include this in the next release.

alexander-sakal commented 10 months ago

Hello @Inovagora. We added a filter that allows to customize the capability required for managing the plugin. Give it a shot and thank you for the suggestion!

Here is an example:

add_filter( 'wp_mail_smtp_core_get_capability_manage_options', function () {
    return 'manage_options';
} );