Merge "Fix history crash" into main