Fix write history bug: conflict name refresh