Fix bug when merge code