fixed problems with merging tool