Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add_filter( 'wcfm_login_redirect', function( $redirect_to, $user ) {
- if ( isset($user->roles) && is_array($user->roles) ) {
- if ( in_array( 'wcfm_vendor', $user->roles ) ) {
- $redirect_to = home_url();
- }
- }
- return $redirect_to;
- }, 10, 2 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement