I'd prefer just `if node['java']['set_default_jdk'] and ...`