Updated code to match style guide