Skip to content
Myr

By default a Buffer passed through res.send() is application/octet-stream

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Tj Holowaychuk · committed by Tj Holowaychuk · parent 5a48248 · Browse files · 2 files+6 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

2 files+6 added−2 removed

  • tests:+1 added−1 removed
  • other:+5 added−1 removed

2 files+6 added−2 removed

modified:lib/express/response.js+5 added-1 removed
modified:test/response.test.js+1 added-1 removed
52 unmodified lines
53 { url: '/error' },54 { body: 'Oh shit!', status: 500, headers: { 'Content-Type': 'text/plain' }});55 assert.response(app,56 { url: '/buffer' },57 { body: 'wahoo!' });57 { body: 'wahoo!', headers: { 'Content-Type': 'application/octet-stream' }});58 },59 60 '#contentType': function(assert){61 var app = express.createServer();
113 unmodified lines