Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- * The following three hooks remove the session actions used in the autoship native ui.
- * Note when not using the Session variable the Native UI option should not be used for Schedule Orders.
- */
- function xx_remove_autoship_session_init_hooks(){
- remove_action( 'init', 'autoship_start_session', 1);
- }
- add_action( 'init', 'xx_remove_autoship_session_init_hooks', 0 );
- function xx_remove_autoship_session_logout_hooks(){
- remove_action('wp_logout', 'autoship_end_session', 10);
- }
- add_action( 'wp_logout', 'xx_remove_autoship_session_logout_hooks', 9 );
- function xx_remove_autoship_session_login_hooks(){
- remove_action('wp_login', 'autoship_end_session', 10);
- }
- add_action( 'wp_login', 'xx_remove_autoship_session_login_hooks', 9 );
Add Comment
Please, Sign In to add comment