text: "use strict";
  
  exports.__esModule = true;
  exports["default"] = lruCache;
  
  function lruCache(limit, equals) {
    var entries = [];
  
    function get(key) {
      for (var i = 0; i < entries.length; i++) {
        var entry = entries[i];
        if (equals(key, entry.key)) {
          if (i > 0) {
            // move this entry to the top of the cache
            entries.splice(i, 1);
            entries.unshift(entry);
          }
          return entry.value;
        }
      }
    }
  
    function put(key, value) {
      if (!get(key)) {
        entries.unshift({ key: key, value: value });
        if (entries.length > limit) {
          entries.pop();
        }
      }
    }
  
    return { get: get, put: put };
  }
  
  module.exports = exports["default"];