title: check if each value in array matches any value in another array using indexOf in google apps scripts
body: <p>Not sure what I'm doing wrong.</p>
  
  <pre><code>function ccheck(){
    var tkhContacts = SpreadsheetApp.openById('##').getSheetByName('contacts');
    var emf = ContactsApp.getContactGroup('emf').getContacts(); 
    var fullNames = emf.map( function(contact){ return contact.getFullName() } );
    var tkhContacts = tkhContacts.getRange('B2:B').getValues();
  
     for(var i=0;i&lt;fullNames.length;i++){
           if(fullNames[i].indexOf(tkhContacts) == -1){
         Logger.log('missing')}
       }
     }
  </code></pre>
  
  <p>Trying to put all Google contacts in group 'emf' into an array. Then taking contact names stored in column B in sheet and putting that in an array. Then take each name in the 'fullNames' array and check if it matches any of the names in 'tkhContacts' from the sheet. If a name in 'fullNames' does not match any name in 'tkhContacts' set value as false.</p>