code: function (i) {
          var deferred = $.Deferred();
          deferreds.push(deferred);
  
          var originalVal = changes[i][3];
          var lowercaseVal = typeof originalVal === 'string' ? originalVal.toLowerCase() : null;
  
          return function (source) {
            var found = false;
            for (var s = 0, slen = source.length; s < slen; s++) {
              if (originalVal === source[s]) {
                found = true; //perfect match
                break;
              }
              else if (lowercaseVal === source[s].toLowerCase()) {
                changes[i][3] = source[s]; //good match, fix the case
                found = true;
                break;
              }
            }
            if (!found) {
              changes[i] = null;
            }
            deferred.resolve();
          }
        }
docs: validate strict autocompletes