Index: src/messages.cc |
diff --git a/src/messages.cc b/src/messages.cc |
index 8b02aa316368f8be68da0bb1d40b81b4872d1f36..d5a15256b9fa0cfd75b5fda18aaa972dc15d47bf 100644 |
--- a/src/messages.cc |
+++ b/src/messages.cc |
@@ -98,7 +98,7 @@ |
MaybeHandle<Object> maybe_stringified; |
Handle<Object> stringified; |
// Make sure we don't leak uncaught internally generated Error objects. |
- if (argument->IsJSError()) { |
+ if (Object::IsErrorObject(isolate, argument)) { |
Handle<Object> args[] = {argument}; |
maybe_stringified = Execution::TryCall( |
isolate, isolate->no_side_effects_to_string_fun(), |