7d2ad53e by Jeff Balicki

wpo365_user_created

Signed-off-by: Jeff <jeff@gotenzing.com>
1 parent 8add9d28
...@@ -299,15 +299,16 @@ add_action( 'profile_update', function ( $user_id, $old_user_data ) { ...@@ -299,15 +299,16 @@ add_action( 'profile_update', function ( $user_id, $old_user_data ) {
299 299
300 } 300 }
301 301
302 //add_action( 'wpo365/user/creating', 'registration_redirect', 10, 1 );
303 302
304 function registration_redirect() {
305 303
306 error_log('registration_redirect'); 304 // Add your custom function to the wpo365_user_created hook
307 wp_redirect(site_url('/account/profile/')); 305 add_action('wpo365_user_created', 'custom_redirect_after_user_created', 10, 2);
308 error_log('redirected');
309 306
310 } 307 function custom_redirect_after_user_created($user_id, $provider) {
311 308
309 error_log('registration_redirect');
310 // Redirect the user after user creation based on your requirements
311 wp_redirect('/account/profile/');
312 exit();
312 313
313 add_filter( 'registration_redirect', 'registration_redirect' );
...\ No newline at end of file ...\ No newline at end of file
314 }
......