nit: add braces around the if statement body