fixing some merging problems