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

Unified Diff: third_party/WebKit/Source/devtools/front_end/persistence/DefaultMapping.js

Issue 2546583003: DevTools: [Persistence] guard against multiple UISourceCodes with similar URL (Closed)
Patch Set: put check deep down Created 4 years 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/Source/devtools/front_end/persistence/Automapping.js ('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/persistence/DefaultMapping.js
diff --git a/third_party/WebKit/Source/devtools/front_end/persistence/DefaultMapping.js b/third_party/WebKit/Source/devtools/front_end/persistence/DefaultMapping.js
index 26ccb97a0d5fbe5d901ac3a48f91a94ffa04ab99..13106fb2a60d4731e37fa5fdfd0cb38ac08b1488 100644
--- a/third_party/WebKit/Source/devtools/front_end/persistence/DefaultMapping.js
+++ b/third_party/WebKit/Source/devtools/front_end/persistence/DefaultMapping.js
@@ -92,6 +92,10 @@ Persistence.DefaultMapping = class {
var binding = this._createBinding(uiSourceCode);
if (!binding)
return;
+ // TODO(lushnikov): remove this check once there's a single uiSourceCode per url. @see crbug.com/670180
+ if (binding.network[Persistence.DefaultMapping._binding] || binding.fileSystem[Persistence.DefaultMapping._binding])
+ return;
+
this._bindings.add(binding);
binding.network[Persistence.DefaultMapping._binding] = binding;
binding.fileSystem[Persistence.DefaultMapping._binding] = binding;
« no previous file with comments | « third_party/WebKit/Source/devtools/front_end/persistence/Automapping.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698