removed console.log statements + duplicate variable declaration