mirror of
https://github.com/node-red/node-red.git
synced 2025-03-01 10:36:34 +00:00
Ensure plugins api provides a filtered view
This commit is contained in:
@@ -65,7 +65,12 @@ function filterNodeInfo(n) {
|
||||
r.err = n.err;
|
||||
}
|
||||
if (n.hasOwnProperty("plugins")) {
|
||||
r.plugins = n.plugins;
|
||||
r.plugins = n.plugins.map(p => {
|
||||
return {
|
||||
id: p.id,
|
||||
type: p.type
|
||||
}
|
||||
});
|
||||
}
|
||||
if (n.type === "plugin") {
|
||||
r.editor = !!n.template;
|
||||
|
||||
Reference in New Issue
Block a user