Refactored the code for a new syntax.