Refactor CoffeeScript code.