diff --git a/packages/node_modules/@node-red/editor-client/src/js/nodes.js b/packages/node_modules/@node-red/editor-client/src/js/nodes.js index cdaf0e00a..a7bfc1191 100644 --- a/packages/node_modules/@node-red/editor-client/src/js/nodes.js +++ b/packages/node_modules/@node-red/editor-client/src/js/nodes.js @@ -2560,11 +2560,17 @@ RED.nodes = (function() { junctions = {}; junctionsByZ = {}; + var workspaceIds = Object.keys(workspaces); + // Ensure all workspaces are unlocked so we don't get any edit-protection + // preventing removal + workspaceIds.forEach(function(id) { + workspaces[id].locked = false + }); + var subflowIds = Object.keys(subflows); subflowIds.forEach(function(id) { RED.subflow.removeSubflow(id) }); - var workspaceIds = Object.keys(workspaces); workspaceIds.forEach(function(id) { RED.workspaces.remove(workspaces[id]); });