Fixed problems with merge