added merge on inputs