Fix UI bug when collections and datasets in same history have same id.