Minor fix in keeping track of history