our map stores arrays by event type, just because it's better than storing everything in a single array. uses '$' as a prefix for the keys for safety
18869
function (element, type, original) {
                // we're not using forAll here simply because it's a bit slower and this
                // needs to be fast
                var i, list = map['$' + type]
                if (list) {
                  for (i = list.length; i--;) {
                    if (list[i].matches(element, original, null))
                      return true
                  }
                }
                return false
              }
558094
function singleToMulti(mapping) {
  const newMapping = {};
  Object.entries(mapping.mapping).forEach(m => {
    newMapping[m[0]] = [m[1]];
  });
  return {
    created: mapping.created,
    fields: [mapping.field],
    key: mapping.key,
    mapping: newMapping
  };
}
1328340
function arrayToStr(key, value) {
  if (isString(value) || isNumber(value)) return `${key}=${value}`;
  if (isString(value[0])) return `${key}=${value.join(':')}`;
  if (value && value.toString) return `${key}=${value.toString()}`;

  return value.map(val => arrayToStr(key, val));
}
593361
def keys
      map { |line| line.kind_of?(Array) ? line.first.key : line.key }
    end
765536
function GetValues(mydata, keys, index)
{
	//Output
	var values = [];
	
	//Loop
	for(var j = 0; j < keys.length; j++)
	{
		//Save data value
		var value = mydata[keys[j]];
		
		//Check if value exists
		if(!value)
		{
			//Show warning
			console.log('WARNING: value "' + keys[j] + '" is not defined on element "' + index + '" of your array.');
			
			//Set it to empty string
			value = '';
		}
		
		//Check the data type
		if(typeof value === 'string' || value instanceof String)
		{
			//Add the quotes
			value = '"' + value + '"';
		}
		
		//Push
		values.push(value);
	}
	
	//Return
	return values.join(',');
}
946316
function HashMap(array, isolatedUid) {
  if (isolatedUid) {
    var uid = 0;
    this.nextUid = function() {
      return ++uid;
    };
  }
  forEach(array, this.put, this);
}
29422
function ( resp ) {
	    	if ( resp instanceof Array ) {
	    		var arr = [];
	    		for ( var i = 0; i < resp.length; i++ ) {
	    			arr.push( expandEventToObject( resp[i] ) );
	    		}
	    		return arr;
	    	}
	    	return resp;
	    }
131769
function arrayMap$1(array, iteratee) {
  var index = -1,
      length = array == null ? 0 : array.length,
      result = Array(length);

  while (++index < length) {
    result[index] = iteratee(array[index], index, array);
  }
  return result;
}
1009154
function mapCacheSet$1(key, value) {
  var data = getMapData$4(this, key),
      size = data.size;

  data.set(key, value);
  this.size += data.size == size ? 0 : 1;
  return this;
}
815206
function (names) {
        this.names = Object.keys(names); // store the keys
        this.hash = util.map(names, function (value) { // store values for corresponding keys
            return parseInt(value, 10);
        });
    }
1364177
function (arr) {
        if (!_.isArray(arr)) {
            return;
        }

        var obj = {},
            key,
            val,
            i,
            ii;

        for (i = 0, ii = arr.length; i < ii; i += 2) {
            key = arr[i];
            val = arr[i + 1];

            if (_.has(obj, key)) {
                !_.isArray(obj[key]) && (obj[key] = [obj[key]]);
                obj[key].push(val);
            }
            else {
                obj[key] = val;
            }
        }

        return obj;
    }
669304
function (entry) {
                forAll(entry.element, entry.type, null, entry.handler, function (entry, list, i) {
                  list.splice(i, 1)
                  if (list.length === 0)
                    delete map['$' + entry.type]
                  return false
                })
              }
289111
function procesArray(array) {
  if (!array || !Array.isArray(array)) {
    return array;
  }
  return array.map((item, index) => {
    if (typeof item === "string") {
      return localizeString(item);
    }
    return item;
  });
}
805421
function(x, keys_, value) {
  if (isnt(x) || isnt(keys_) || isnt(value))  { return false; }

  var keys  = _.isArray(keys_) ? keys_ : keys_.split('.').map(function(x) {return x==='' ? null: x});

  if (anyIsnt(keys))                          { return false; }

  return keys;
}
839149
function(handlers) {
				var h;
						
				if (Basic.typeOf(handlers) !== 'array') {
					handlers = [handlers];
				}

				for (var i = 0; i < handlers.length; i++) {
					h = 'on' + handlers[i];
					
					if (Basic.typeOf(this[h]) === 'function') {
						this.addEventListener(handlers[i], this[h]);
					} else if (Basic.typeOf(this[h]) === 'undefined') {
						this[h] = null; // object must have defined event properties, even if it doesn't make use of them
					}
				}
			}
193796
function bindMapEvents(scope, eventsStr, googleObject, element) {
    angular.forEach(eventsStr.split(' '), function (eventName) {
      //Prefix all googlemap events with 'map-', so eg 'click' 
      //for the googlemap doesn't interfere with a normal 'click' event
      var $event = { type: 'map-' + eventName };
      google.maps.event.addListener(googleObject, eventName, function (evt) {
        element.trigger(angular.extend({}, $event, evt));
        //We create an $apply if it isn't happening. we need better support for this
        //We don't want to use timeout because tons of these events fire at once,
        //and we only need one $apply
        if (!scope.$$phase) scope.$apply();
      });
    });
  }
872023
function map(ary, each, done) {
  var result = new Array(ary.length);
  var next = after(ary.length, done);

  for (var i = 0; i < ary.length; i++) {
    each(ary[i], function(error, msg) {
      result[i] = msg;
      next(error, result);
    });
  }
}