Index: src/promise.js |
diff --git a/src/promise.js b/src/promise.js |
index 09582a279758b1ba43fb4991c567cc784ca5a211..f2e692d0dea4988b2dd92e18fd0a27b26e95a463 100644 |
--- a/src/promise.js |
+++ b/src/promise.js |
@@ -39,11 +39,6 @@ var lastMicrotaskId = 0; |
if (!IS_SPEC_FUNCTION(resolver)) |
throw MakeTypeError('resolver_not_a_function', [resolver]); |
var promise = PromiseInit(this); |
- if (DEBUG_IS_ACTIVE) { |
- %DebugPromiseEvent({ type : "new", |
- promise: this, |
- resolver: resolver }); |
- } |
try { |
%DebugPromiseHandlePrologue(function() { return promise }); |
resolver(function(x) { PromiseResolve(promise, x) }, |
@@ -62,8 +57,9 @@ var lastMicrotaskId = 0; |
SET_PRIVATE(promise, promiseValue, value); |
SET_PRIVATE(promise, promiseOnResolve, onResolve); |
SET_PRIVATE(promise, promiseOnReject, onReject); |
- if (DEBUG_IS_ACTIVE && status !== 0) { |
- %DebugPromiseEvent({ type: "update", |
+ if (DEBUG_IS_ACTIVE) { |
+ var type = status === 0 ? "new" : "update"; |
aandrey
2014/08/01 07:46:18
remove this and the "type". if you really need it,
Alexandra Mikhaylova
2014/08/01 12:23:06
Removed this as we can tell the type of event usin
|
+ %DebugPromiseEvent({ type: type, |
promise: promise, |
status: status, |
value: value }); |