fixing missed history lenght