I have this array's and I want to replace the data form the array1 with the data of array2 if there is some coincident, for example that replace from the array1 {"Dates":"05/25/2021","valor":"0"} the data of array2 {Dates: "05/25/2021", count: "20"} that match
array1 = [{Dates:"05/10/2021",count:"0"},{Dates:"05/11/2021",count:"0"},{Dates:"05/12/2021",count:"0"},{Dates:"05/13/2021",count:"0"},{Dates:"05/14/2021",count:"0"},{Dates:"05/15/2021",count:"0"},{Dates:"05/16/2021",count:"0"},{Dates:"05/17/2021",count:"0"},{Dates:"05/18/2021",count:"0"},{Dates:"05/19/2021",count:"0"},{Dates:"05/20/2021",count:"0"},{Dates:"05/21/2021",count:"0"},{Dates:"05/22/2021",count:"0"},{Dates:"05/23/2021",count:"0"},{Dates:"05/24/2021",count:"0"},{Dates:"05/25/2021",count:"0"},{Dates:"05/26/2021",count:"0"},{Dates:"05/27/2021",count:"0"},{Dates:"05/28/2021",count:"0"},{Dates:"05/29/2021",count:"0"},{Dates:"05/30/2021",count:"0"},{Dates:"05/31/2021",count:"0"},{Dates:"06/01/2021",count:"0"},{Dates:"06/02/2021",count:"0"},{Dates:"06/03/2021",count:"0"},{Dates:"06/04/2021",count:"0"},{Dates:"06/05/2021",count:"0"},{Dates:"06/06/2021",count:"0"},{Dates:"06/07/2021",count:"0"},{Dates:"06/08/2021",count:"0"}];
array2 = [{Dates: "05/25/2021", count: "20"},{Dates: "05/26/2021", count: "0"},{Dates: "05/27/2021", count: "3"},{Dates: "05/28/2021", count: "10"},{Dates: "06/07/2021", count: "0"}];
if someone can help me I will appreciate, thanks