Node Js Check If Element Exists In Array Javascript Iteration