added code of download tracking