Closed mtharrison closed 8 years ago
Just wondering if there's any good reason that the restful example /generate endpoint responds with text/html and a JSONy looking string:
text/html
server.route({ method: 'GET', path: '/generate', handler: function (request, reply) { // return crumb if desired return reply('{ "crumb": ' + request.plugins.crumb + ' }'); } });
rather than:
server.route({ method: 'GET', path: '/generate', handler: function (request, reply) { // return crumb if desired return reply({ crumb: request.plugins.crumb }); } });
Happy to make a PR if you think it's worth it.
good point. a PR would be appreciated :)
This thread has been automatically locked due to inactivity. Please open a new issue for related bugs or questions following the new issue template instructions.
Just wondering if there's any good reason that the restful example /generate endpoint responds with
text/html
and a JSONy looking string:rather than:
Happy to make a PR if you think it's worth it.