Closed PatrickHeneise closed 12 years ago
ideally we'd just use Accept, since that's what it's for
header.accept = "text/plain", or how do I do that?
alternatively we could white-list formats, but then that gets a bit opinionated and messy, but otherwise it's ambiguous
but yeah we would just parse Accept's values/qualities and see if any of those formats are available
res.contentType('text/html');
Thanks!
I just ran into this issue, passing an email in the url. Where did you put that res.contentType('text/html') code?
I'm authenticating with google and using the e-mail address as user name. For user/show the URL is /user/abc@abc.com. This will always download a file abc@abc.com, even though it should res.render 'user/show'. How can I prevent that? I tried setting req.format and req.params.format to undefined, but didn't work.