Fixed some bug in the stats