Web Inspector: Using Breakpoint Actions Breaks iOS inspection
[WebKit-https.git] / Source / WebInspectorUI / UserInterface / DebuggerManager.js
index 0bdcd541fc83ffb415355bc6f721d40afca9587f..42e01e294ab6408c33c5d849d3013ea4ed3072cd 100644 (file)
@@ -514,10 +514,13 @@ WebInspector.DebuggerManager.prototype = {
 
         // Convert BreakpointAction types to DebuggerAgent protocol types.
         // NOTE: Breakpoint.options returns new objects each time, so it is safe to modify.
-        var options = breakpoint.options;
-        if (options.actions.length) {
-            for (var i = 0; i < options.actions.length; ++i)
-                options.actions[i].type = this._debuggerBreakpointActionType(options.actions[i].type);
+        var options;
+        if (DebuggerAgent.BreakpointActionType) {
+            options = breakpoint.options;
+            if (options.actions.length) {
+                for (var i = 0; i < options.actions.length; ++i)
+                    options.actions[i].type = this._debuggerBreakpointActionType(options.actions[i].type);
+            }
         }
 
         // COMPATIBILITY (iOS 7): iOS 7 and earlier, DebuggerAgent.setBreakpoint* took a "condition" string argument.