Commit f7821596 authored by ben's avatar ben Committed by Commit bot

Remove obsolete try/catch from ObjectIsPromise().

Review URL: https://codereview.chromium.org/1367123003

Cr-Commit-Position: refs/heads/master@{#30966}
parent 660d4fa7
......@@ -107,16 +107,9 @@ function ClearMirrorCache(value) {
}
// Wrapper to check whether an object is a Promise. The call may not work
// if promises are not enabled.
// TODO(yangguo): remove try-catch once promises are enabled by default.
function ObjectIsPromise(value) {
try {
return IS_SPEC_OBJECT(value) &&
!IS_UNDEFINED(%DebugGetProperty(value, promiseStatusSymbol));
} catch (e) {
return false;
}
return IS_SPEC_OBJECT(value) &&
!IS_UNDEFINED(%DebugGetProperty(value, promiseStatusSymbol));
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment