Made application.js way more object oriented