[FIX] add missing return when dependency is not found

Additionally I would suggest to use `console.error` since you log the keyword `'[ERROR]'`