-
-
Save KnowTheCodePro/a1af80064c8f602a7657 to your computer and use it in GitHub Desktop.
This file contains 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 | |
namespace KnowTheCode; | |
add_action( 'loop_start', __NAMESPACE__ . '\code_smell_example' ); | |
function code_smell_example() { | |
return is_page() && ! is_user_logged_in(); | |
// Or even this with the parentheses | |
return ( is_page() && ! is_user_logged_in() ); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment