current_user_can doesn’t work
-
i have this code for tax exempt capabilities
if (is_user_logged_in() && !is_admin()) { add_filter( 'init', 'make_customer_tax_exempt' ); } function make_customer_tax_exempt() { global $woocommerce; $tax_exempt = current_user_can( 'tax_exempt' ); $woocommerce->customer->set_is_vat_exempt( $tax_exempt ); }
with user role editor work, with aam doesn’t work… how can i fix that ?
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘current_user_can doesn’t work’ is closed to new replies.