bugfix for stats