Skip to content

Commit

Permalink
Fix incorrect Arborist API call
Browse files Browse the repository at this point in the history
  • Loading branch information
kemitchell committed Aug 23, 2022
1 parent 3117239 commit 53bd8b2
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion index.js
Expand Up @@ -36,7 +36,10 @@ function licensee (configuration, path, callback) {
var arborist = new Arborist({ path })
arborist.loadActual({ forceActual: true })
.then(function (tree) {
var dependencies = Array.from(tree.children.values())
var dependencies = Array.from(tree.inventory.values())
.filter(function (dependency) {
return !dependency.isProjectRoot
})
if (configuration.filterPackages) {
dependencies = configuration.filterPackages(dependencies)
}
Expand Down

0 comments on commit 53bd8b2

Please sign in to comment.