added a stat counter