Address review comments; fix up content type logic in messageGenerator.js