I have two objects which I am comparing. I have an array of objects, and I am trying to see if the array contains a certain object. I think it should be finding it, but it is not. Here is the object in the array:

and here is the object I am looking for:

I am using:
if (collection.indexOf(object) !== -1) {
  //do something  
}And it returns an index of -1, even though it seems to me that the objects match. Am I missing something here?
 
     
     
    