Update Existing Object In Array Javascript Function How To Use