[node plugin] Don't crash when no projectDir option is specified

Closes #376