Modified tracking code to work with turbolinks