for (var i = selectedArray.length; i--; ) { if ( x.clan == selectedArray[i] ) { return true; } } return x;