Created
December 20, 2019 08:37
-
-
Save corsonr/ab14b645d318d2ed9e5043fa1ff53635 to your computer and use it in GitHub Desktop.
Restrict WooCommerce Subscriptions Creation Process
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 | |
if ( current_user_can( 'edit_pages' ) ) { // Edit capability here. | |
remove_filter( 'product_type_selector', 'WC_Subscriptions_Admin::add_subscription_products_to_select' ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment