Fixed a bug with analytics