fix merging bug