@@ -116,12 +116,13 @@ class LRU {
116116
117117 /**
118118 * Returns an array of [key, value] pairs for the specified keys.
119- * Order follows LRU order (least to most recently used).
119+ * When no keys provided, returns all entries in LRU order.
120+ * When keys provided, order matches the input array.
120121 *
121122 * @method entries
122123 * @memberof LRU
123124 * @param {string[] } [keys=this.keys()] - Array of keys to get entries for. Defaults to all keys.
124- * @returns {Array<Array<*>> } Array of [key, value] pairs in LRU order .
125+ * @returns {Array<Array<*>> } Array of [key, value] pairs.
125126 * @example
126127 * cache.set('a', 1).set('b', 2);
127128 * console.log(cache.entries()); // [['a', 1], ['b', 2]]
@@ -436,12 +437,13 @@ class LRU {
436437
437438 /**
438439 * Returns an array of all values in the cache for the specified keys.
439- * Order follows LRU order (least to most recently used).
440+ * When no keys provided, returns all values in LRU order.
441+ * When keys provided, order matches the input array.
440442 *
441443 * @method values
442444 * @memberof LRU
443445 * @param {string[] } [keys=this.keys()] - Array of keys to get values for. Defaults to all keys.
444- * @returns {Array<*> } Array of values corresponding to the keys in LRU order .
446+ * @returns {Array<*> } Array of values corresponding to the keys.
445447 * @example
446448 * cache.set('a', 1).set('b', 2);
447449 * console.log(cache.values()); // [1, 2]
0 commit comments