Fixed clone to create correct instance type