From 859e181c90d6832c83f2ed6c519440f72ee31fef Mon Sep 17 00:00:00 2001 From: Gabriel Andretta Date: Wed, 27 Jan 2016 20:14:51 -0300 Subject: [PATCH] Fix bundling, closes #94 - Update react to latest version, that way users can upgrade react and avoid the problem of two react versions running alongside. - Change the way the blueimp library is required to avoid issues with webpack. --- package.json | 10 +++++----- src/gravatar/web_api.js | 4 +++- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/package.json b/package.json index d4ed155..d44d63d 100644 --- a/package.json +++ b/package.json @@ -55,7 +55,7 @@ "grunt-exec": "^0.4.6", "grunt-http": "^1.6.0", "mochify": "^2.12.0", - "react-addons-test-utils": "0.14.5", + "react-addons-test-utils": "0.14.6", "sinon": "^1.15.4", "unreleased": "^0.1.0", "zuul": "^3.2.0", @@ -67,10 +67,10 @@ "fbjs": "^0.3.1", "immutable": "^3.7.3", "jsonp": "^0.2.0", - "react": "0.14.5", - "react-addons-css-transition-group": "0.14.5", - "react-addons-transition-group": "0.14.5", - "react-dom": "0.14.5", + "react": "0.14.6", + "react-addons-css-transition-group": "0.14.6", + "react-addons-transition-group": "0.14.6", + "react-dom": "0.14.6", "reqwest": "^1.1.4", "trim": "0.0.1" } diff --git a/src/gravatar/web_api.js b/src/gravatar/web_api.js index 98ddf77..bc46745 100644 --- a/src/gravatar/web_api.js +++ b/src/gravatar/web_api.js @@ -1,8 +1,10 @@ -import { md5 } from 'blueimp-md5'; +import blueimp from 'blueimp-md5'; import { validateEmail } from '../cred/index'; import jsonp from '../utils/jsonp_utils'; import * as preload from '../preload/index'; +const md5 = blueimp.md5 || blueimp; + export function profile(email, success, error) { if (validateEmail(email)) { const url = `https://secure.gravatar.com/${md5(email)}.json`;