Created
December 16, 2021 15:38
-
-
Save greenhornet79/0177124ad86f20444a93ceb1ca9e0efa to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// adjust who can edit and manage the Leaky Paywall settings menu | |
// use WordPress capabilities https://wordpress.org/support/article/roles-and-capabilities/ | |
add_filter( 'manage_leaky_paywall_settings', 'zeen101_adjust_lp_setting_management' ); | |
function zeen101_adjust_lp_setting_management( $cap ) { | |
// allow editors | |
return 'delete_others_posts'; | |
// allow editors and authors | |
return 'edit_posts'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment