Created
May 2, 2018 13:46
-
-
Save FernandoSalinas33/d2169955ee384a58ef18fc20f29e7424 to your computer and use it in GitHub Desktop.
Change WooCommerce Registration Role to Employer.
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
add_filter('woocommerce_new_customer_data', 'wc_assign_custom_role', 10, 1); | |
function wc_assign_custom_role($args) { | |
$args['role'] = 'employer'; | |
return $args; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment