From a85267a786980873e47b3cd1cebb5e06f0aa7fe3 Mon Sep 17 00:00:00 2001 From: Michael Jackson Date: Sat, 30 Aug 2014 12:33:38 -0700 Subject: [PATCH] Use when instead of es6-promise Fixes #194 --- modules/components/Routes.js | 2 +- modules/helpers/resolveAsyncState.js | 2 +- package.json | 6 +++--- specs/AsyncState.spec.js | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/modules/components/Routes.js b/modules/components/Routes.js index 5b0ae3142e..9220541824 100644 --- a/modules/components/Routes.js +++ b/modules/components/Routes.js @@ -1,7 +1,7 @@ var React = require('react'); var warning = require('react/lib/warning'); var copyProperties = require('react/lib/copyProperties'); -var Promise = require('es6-promise').Promise; +var Promise = require('when/lib/Promise'); var LocationActions = require('../actions/LocationActions'); var Route = require('../components/Route'); var Path = require('../helpers/Path'); diff --git a/modules/helpers/resolveAsyncState.js b/modules/helpers/resolveAsyncState.js index 5faee7f1d4..effb050d65 100644 --- a/modules/helpers/resolveAsyncState.js +++ b/modules/helpers/resolveAsyncState.js @@ -1,4 +1,4 @@ -var Promise = require('es6-promise').Promise; +var Promise = require('when/lib/Promise'); /** * Resolves all values in asyncState and calls the setState diff --git a/package.json b/package.json index 2ceb92fa7f..62769de93e 100644 --- a/package.json +++ b/package.json @@ -48,10 +48,10 @@ "react": ">=0.11.0" }, "dependencies": { - "es6-promise": "1.0.0", "events": "1.0.1", "flux": "2.0.0", - "qs": "1.2.2" + "qs": "1.2.2", + "when": "^3.4.4" }, "keywords": [ "react", @@ -64,4 +64,4 @@ "browserify-shim": { "react": "global:React" } -} \ No newline at end of file +} diff --git a/specs/AsyncState.spec.js b/specs/AsyncState.spec.js index 17087c287f..a1e5dd1922 100644 --- a/specs/AsyncState.spec.js +++ b/specs/AsyncState.spec.js @@ -1,5 +1,5 @@ require('./helper'); -var Promise = require('es6-promise').Promise; +var Promise = require('when/lib/Promise'); var AsyncState = require('../modules/mixins/AsyncState'); describe('AsyncState', function () {