summaryrefslogtreecommitdiff
path: root/lib/_debugger.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/_debugger.js')
-rw-r--r--lib/_debugger.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/_debugger.js b/lib/_debugger.js
index 2613d8bbbe..4dd9f53633 100644
--- a/lib/_debugger.js
+++ b/lib/_debugger.js
@@ -1367,7 +1367,9 @@ Interface.prototype.setBreakpoint = function(script, line,
if (script != +script && !this.client.scripts[script]) {
var scripts = this.client.scripts;
Object.keys(scripts).forEach(function(id) {
- if (scripts[id] && scripts[id].name.indexOf(script) !== -1) {
+ if (scripts[id] &&
+ scripts[id].name &&
+ scripts[id].name.indexOf(script) !== -1) {
if (scriptId) {
ambiguous = true;
}