refactor
refactor done using Backbone