diff options
author | Samy Pesse <samypesse@gmail.com> | 2016-05-02 22:01:05 +0200 |
---|---|---|
committer | Samy Pesse <samypesse@gmail.com> | 2016-05-02 22:01:05 +0200 |
commit | 20f1cf3dff685ead53c85a9cd751ae9dacea7289 (patch) | |
tree | e6b83ed38004e6df2f9008d2bfba0098f2523e6d /lib/utils/promise.js | |
parent | c87060454ec8bbc89d7acdd5c7ef9006242a6930 (diff) | |
download | gitbook-20f1cf3dff685ead53c85a9cd751ae9dacea7289.zip gitbook-20f1cf3dff685ead53c85a9cd751ae9dacea7289.tar.gz gitbook-20f1cf3dff685ead53c85a9cd751ae9dacea7289.tar.bz2 |
Enable promise long stack trace when testing or debugging
Diffstat (limited to 'lib/utils/promise.js')
-rw-r--r-- | lib/utils/promise.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/utils/promise.js b/lib/utils/promise.js index 19d7554..138546b 100644 --- a/lib/utils/promise.js +++ b/lib/utils/promise.js @@ -1,6 +1,11 @@ var Q = require('q'); var Immutable = require('immutable'); +// Debugging for long stack traces +if (global.__DEV__ || process.env.DEBUG) { + Q.longStackSupport = true; +} + /** Reduce an array to a promise |