From 6a1a679fc9fc767729266fe86a2a68f771c22d76 Mon Sep 17 00:00:00 2001 From: Jeff Avallone Date: Thu, 10 Mar 2016 17:32:33 -0500 Subject: [PATCH] Updating lodash version --- package.json | 2 +- src/js/parser/javascript/charset.js | 2 +- src/js/parser/javascript/root.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index fb7df56..e1052af 100644 --- a/package.json +++ b/package.json @@ -36,7 +36,7 @@ "karma-chrome-launcher": "^0.2.2", "karma-jasmine": "^0.3.1", "karma-notify-reporter": "^0.1.1", - "lodash": "^3.10.1", + "lodash": "^4.6.1", "node-bourbon": "^4.2.3", "snapsvg": "^0.4.0", "through": "^2.3.8", diff --git a/src/js/parser/javascript/charset.js b/src/js/parser/javascript/charset.js index a56e1b0..a021126 100644 --- a/src/js/parser/javascript/charset.js +++ b/src/js/parser/javascript/charset.js @@ -54,7 +54,7 @@ export default { // and text value of the part, so `[aa]` will have only one item, but // `[a\x61]` will contain two since the first matches "a" and the second // matches 0x61 (even though both are an "a"). - this.elements = _.unique(this.properties.parts.elements, part => { + this.elements = _.uniqBy(this.properties.parts.elements, part => { return `${part.type}:${part.textValue}`; }); diff --git a/src/js/parser/javascript/root.js b/src/js/parser/javascript/root.js index 87567d4..c50d720 100644 --- a/src/js/parser/javascript/root.js +++ b/src/js/parser/javascript/root.js @@ -47,7 +47,7 @@ export default { setup() { // Convert list of flags into text describing each flag. - this.flags = _(this.properties.flags.textValue).unique().sort().map(flag => { + this.flags = _(this.properties.flags.textValue).uniq().sort().map(flag => { return this.flagLabels[flag]; }).value();