fixes global stats bug