Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

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 plugin-republic/a7a474777c8a9627d566af0c658f6593 to your computer and use it in GitHub Desktop.
Save plugin-republic/a7a474777c8a9627d566af0c658f6593 to your computer and use it in GitHub Desktop.
Remove WooCommerce notice when user registers new account
<?php
/**
* Remove WooCommerce notice when user registers new account
*/
function wcmo_remove_new_registration_notice( $notice_message ) {
if( strpos( $notice_message, 'Your account was created successfully' ) !== false ) {
return '';
}
return $notice_message;
}
add_filter( 'woocommerce_add_success', 'wcmo_remove_new_registration_notice', 99, 1 );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment