Fix tracker

This commit is contained in:
René Pfeuffer
2019-09-16 17:49:21 +02:00
parent b2294b8ae1
commit 0243edf585
2 changed files with 2 additions and 8 deletions

View File

@@ -27,16 +27,10 @@ class PluginDependencyTracker {
}
private void addDependency(String from, String to) {
plugins.computeIfAbsent(to, name -> createInitialDependencyCollection(from));
plugins.computeIfAbsent(to, name -> new HashSet<>()).add(from);
}
private void removeDependency(String from, String to) {
plugins.get(to).remove(from);
}
private Collection<String> createInitialDependencyCollection(String from) {
Collection<String> dependencies = new HashSet<>();
dependencies.add(from);
return dependencies;
}
}