1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Handle manually added project deps that are unused

Fixes #1908
This commit is contained in:
Nick O'Leary 2018-10-07 11:11:30 +01:00
parent e03a0fffa9
commit 629536b562
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9

View File

@ -461,7 +461,11 @@ RED.projects.settings = (function() {
setTimeout(function() { setTimeout(function() {
depsList.editableList('removeItem',entry); depsList.editableList('removeItem',entry);
refreshModuleInUseCounts(); refreshModuleInUseCounts();
entry.count = modulesInUse[entry.id].count; if (modulesInUse.hasOwnProperty(entry.id)) {
entry.count = modulesInUse[entry.id].count;
} else {
entry.count = 0;
}
depsList.editableList('addItem',entry); depsList.editableList('addItem',entry);
},500); },500);
} }