Updated merge handling