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
1 changed files with 5 additions and 1 deletions

View File

@ -461,7 +461,11 @@ RED.projects.settings = (function() {
setTimeout(function() {
depsList.editableList('removeItem',entry);
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);
},500);
}