Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion lib/util.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

const uv = process.binding('uv');
const Buffer = require('buffer').Buffer;
const Debug = require('vm').runInDebugContext('Debug');
const internalUtil = require('internal/util');
var Debug;

const formatRegExp = /%[sdj%]/g;
exports.format = function(f) {
Expand Down Expand Up @@ -168,6 +168,7 @@ function arrayToHash(array) {


function inspectPromise(p) {
Debug = Debug || require('vm').runInDebugContext('Debug');
var mirror = Debug.MakeMirror(p, true);
if (!mirror.isPromise())
return null;
Expand Down