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

Unified Diff: third_party/WebKit/Source/devtools/front_end/sass/SASSSourceMapFactory.js

Issue 1965223003: DevTools: liveSASS should tolerate race between iNotify and BrowserSync (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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
« no previous file with comments | « third_party/WebKit/LayoutTests/inspector/sass/test-mapping-with-cache-busting-url-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/devtools/front_end/sass/SASSSourceMapFactory.js
diff --git a/third_party/WebKit/Source/devtools/front_end/sass/SASSSourceMapFactory.js b/third_party/WebKit/Source/devtools/front_end/sass/SASSSourceMapFactory.js
index 4071fd1c193d4ec0b61c5d413383982bf6177f90..91e5d23d62d24514a3cad41407edc0937168393a 100644
--- a/third_party/WebKit/Source/devtools/front_end/sass/SASSSourceMapFactory.js
+++ b/third_party/WebKit/Source/devtools/front_end/sass/SASSSourceMapFactory.js
@@ -24,10 +24,9 @@ WebInspector.SASSSourceMapFactory.prototype = {
if (!cssModel)
return Promise.resolve(/** @type {?WebInspector.SourceMap} */(null));
- var headerIds = cssModel.styleSheetIdsForURL(sourceMap.compiledURL());
- if (!headerIds || !headerIds.length)
+ var header = cssModel.styleSheetHeaders().find(styleSheetHeader => styleSheetHeader.sourceMapURL === sourceMap.url());
+ if (!header)
return Promise.resolve(/** @type {?WebInspector.SourceMap} */(null));
- var header = cssModel.styleSheetHeaderForId(headerIds[0]);
/** @type {!Map<string, !WebInspector.SASSSupport.AST>} */
var models = new Map();
« no previous file with comments | « third_party/WebKit/LayoutTests/inspector/sass/test-mapping-with-cache-busting-url-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698