Control whether new users see the password change nag after their account is created with a random, temporary password. SureCart uses default WordPress functionality for best compatibility, so you can use the get_user_metadata filter to intercept the default_password_nag user meta check.
add_filter( 'get_user_metadata', function( $value, $object_id, $meta_key, $single ) { if ( 'default_password_nag' === $meta_key ) { return ''; // Return empty to prevent password nag from showing } return $value;}, 10, 4 );
add_filter( 'get_user_metadata', function( $value, $object_id, $meta_key, $single ) { if ( 'default_password_nag' !== $meta_key ) { return $value; } // Don't nag users who signed up via social login if ( get_user_meta( $object_id, 'social_login', true ) ) { return ''; // Return empty to prevent password nag from showing } return $value;}, 10, 4 );