many bug fixes with external npm modules