Fixed bug in clearing stats history.