Created
July 18, 2017 08:13
-
-
Save kreamweb/91385e2bd26e6ac616b889f6f3a626ab to your computer and use it in GitHub Desktop.
This code hide the messages to all user that can't earn points.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| if( ! function_exists('YITH_WC_Points_Rewards') ){ | |
| add_filter('ywpar_hide_messages', 'ywpar_hide_messages' ); | |
| function ywpar_hide_messages( $result ){ | |
| if ( ! YITH_WC_Points_Rewards()->is_user_enabled( ) ) { | |
| $result = true; | |
| } | |
| return $result; | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment