cleaned up coffeescript