Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(703)

Unified Diff: third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js

Issue 2422803002: DevTools: prefix node.js scripts's sourceURL with "file://" to make them a valid url (Closed)
Patch Set: Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js
diff --git a/third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js b/third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js
index 20f722c8d7d6d60b5253f968e0b66e5d9df16082..fe05763885f3957ade1d855caa60cbbbf05850c2 100644
--- a/third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js
+++ b/third_party/WebKit/Source/devtools/front_end/sdk/DebuggerModel.js
@@ -474,6 +474,9 @@ WebInspector.DebuggerModel.prototype = {
var isContentScript = false;
if (executionContextAuxData && ("isDefault" in executionContextAuxData))
isContentScript = !executionContextAuxData["isDefault"];
+ // Support file URL for node.js.
+ if (Runtime.queryParam("v8only") && sourceURL && sourceURL.startsWith("/"))
pfeldman 2016/10/15 00:42:35 - In case when Node target is attached from within
lushnikov 2016/10/15 00:59:03 Handled (1) via the Target.isNodeJS() We're in a
+ sourceURL = "file://" + sourceURL;
var script = new WebInspector.Script(this, scriptId, sourceURL, startLine, startColumn, endLine, endColumn, executionContextId, hash, isContentScript, isLiveEdit, sourceMapURL, hasSourceURL);
this._registerScript(script);
if (!hasSyntaxError)

Powered by Google App Engine
This is Rietveld 408576698