I am really new to the world of angularjs and I am working on angular 1.5
What I am trying to do is remove the duplicate records from the response before assigning it to the $scope
The results that i get looks like as following
[
{
    "phoneNumbers": [
      {
        "value": "00 1 111-222-333",
        "pref": false,
        "id": 0,
        "type": null
      },
      {
        "value": "00 1 222-222-333",
        "pref": false,
        "id": 1,
        "type": null
      },
      {
        "value": "00 1 333-222-333",
        "pref": false,
        "id": 2,
        "type": null
      }
    ]
  },{
    "phoneNumbers": [
      {
        "value": "00 1 111-222-333",
        "pref": false,
        "id": 0,
        "type": null
      },
      {
        "value": "00 1 222-222-333",
        "pref": false,
        "id": 1,
        "type": null
      },
      {
        "value": "00 1 333-222-333",
        "pref": false,
        "id": 2,
        "type": null
      }
    ]
  }]
You will notice that there are 2 arrays and both have sub array called phoneNumbers and they have the exact same value.
What I need is if phoneNumbers of any array matches the phoneNumbers of another array then remove that array all together from the response.
I will really appreciate any help on this.

 
     
    