mirror of
https://github.com/node-red/node-red.git
synced 2023-10-10 13:36:53 +02:00
Fix RED.nodes.clear() when handling locked flows
This commit is contained in:
parent
6bd67ae68c
commit
3630056ed8
@ -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]);
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user