Skip to content

Commit

Permalink
devtools: fix broken switchPrompt functionality
Browse files Browse the repository at this point in the history
  • Loading branch information
darwin committed Sep 1, 2016
1 parent fb582e0 commit 75065e3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions resources/unpacked/devtools/front_end/console/ConsoleView.js
Original file line number Diff line number Diff line change
Expand Up @@ -1179,7 +1179,7 @@ WebInspector.ConsoleView.prototype = {
_findPromptIndexById: function(id) {
for (var i=0; i<this._prompts.length; i++) {
var promptDescriptor = this._prompts[i];
if (promptDescriptor.id == id) {
if (promptDescriptor.id === id) {
return i;
}
}
Expand All @@ -1188,7 +1188,7 @@ WebInspector.ConsoleView.prototype = {

switchPrompt: function(promptId) {
var selectedPromptIndex = this._findPromptIndexById(promptId);
if (!selectedPromptIndex) {
if (selectedPromptIndex === null) {
console.warn("switchPrompt: unknown prompt id ", promptId);
return;
}
Expand Down

0 comments on commit 75065e3

Please sign in to comment.