From afc4c93119b0356de39d72702965072704c733ef Mon Sep 17 00:00:00 2001 From: Mees van Dijk Date: Fri, 13 May 2016 01:27:13 +0200 Subject: [PATCH] Fixed Cache.has function (#344) * Fixed Cache.has function * Fixed Cache.has function * Fixed Cache.has function and ran grunt --dev --- lib/Util/Cache.js | 4 ++-- src/Util/Cache.js | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/Util/Cache.js b/lib/Util/Cache.js index 61c13b8e3..24ba54a9f 100644 --- a/lib/Util/Cache.js +++ b/lib/Util/Cache.js @@ -59,8 +59,8 @@ var Cache = (function (_Array) { return null; }; - Cache.prototype.has = function has(object) { - return !!this.get(this[discrimS], object[this[discrimS]]); + Cache.prototype.has = function has(key, value) { + return !!this.get(key, value); }; Cache.prototype.getAll = function getAll(key, value) { diff --git a/src/Util/Cache.js b/src/Util/Cache.js index 9cbf6dc91..d1d78dd5a 100644 --- a/src/Util/Cache.js +++ b/src/Util/Cache.js @@ -36,8 +36,8 @@ export default class Cache extends Array { return null; } - has(object) { - return !!this.get(this[discrimS], object[this[discrimS]]); + has(key, value) { + return !!this.get(key, value); } getAll(key, value) {