Fix bug in improvement.