Switch an entire nav menu if user is logged in
There are a couple of issues with the original code. In the if statement, $args[‘menu’] is being set to Non-Members Area (which will then evaluate to true). It looks like you actually want to be doing an equality check there. A good way to avoid this is to use Yoda conditions. Also, the $args array …