From c6e536a768932f227df5a49979f40b45666b56c9 Mon Sep 17 00:00:00 2001 From: John-David Dalton Date: Mon, 1 Sep 2014 23:44:28 -0700 Subject: [PATCH] Use `metaMap` inference instead of `WeakMap`. --- lodash.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lodash.js b/lodash.js index 6dbb79143..74dcf150b 100644 --- a/lodash.js +++ b/lodash.js @@ -2212,7 +2212,7 @@ * @param {*} data The metadata. * @returns {Function} Returns `func`. */ - var baseSetData = !WeakMap ? identity : function(func, data) { + var baseSetData = !metaMap ? identity : function(func, data) { metaMap.set(func, data); return func; }; @@ -2808,7 +2808,7 @@ * @param {Function} func The function to query. * @returns {*} Returns the metadata for `func`. */ - var getData = !WeakMap ? noop : function(func) { + var getData = !metaMap ? noop : function(func) { return metaMap.get(func); };