diff --git a/src/node.cc b/src/node.cc index 26677eaeb60..818c1a46bc8 100644 --- a/src/node.cc +++ b/src/node.cc @@ -991,9 +991,13 @@ MakeCallback(const Handle object, Local callback_v = object->Get(symbol); if (!callback_v->IsFunction()) { String::Utf8Value method(symbol); - fprintf(stderr, "method = %s", *method); + // XXX: If the object has a domain attached, handle it there? + // At least, would be good to get *some* sort of indication + // of how we got here, even if it's not catchable. + fprintf(stderr, "Non-function in MakeCallback. method = %s\n", *method); + abort(); } - assert(callback_v->IsFunction()); + Local callback = Local::Cast(callback_v); return scope.Close(MakeCallback(object, callback, argc, argv));