Skip to content

Instantly share code, notes, and snippets.

@FernandoSalinas33
Created July 23, 2018 18:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save FernandoSalinas33/6acfa90edc8e00a088ee49c0127a3175 to your computer and use it in GitHub Desktop.
Save FernandoSalinas33/6acfa90edc8e00a088ee49c0127a3175 to your computer and use it in GitHub Desktop.
Make Vendor Admin the default WooCommerce Registration Role
add_filter('woocommerce_new_customer_data', 'wc_assign_custom_role', 10, 1);
function wc_assign_custom_role($args) {
$args['role'] = 'wc_product_vendors_admin_vendor';
return $args;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment