Fallback to module installs if package.json is missing in a local folder install

Fixes #6117
this line is unnecessary – the stat call below will fail either way