Fixes for analyticstracking issue and issues 2 & 3 of github