Skip to content
Myr

docs

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 163256b · Browse files · 1 file+5 added−1 removed
This commit

State

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

Diff stats

1 file+5 added−1 removed

  • other:+5 added−1 removed

1 file+5 added−1 removed

modified:lib/express/request.js+5 added-1 removed
82 unmodified lines
83 */8485http.IncomingMessage.prototype.accepts = function(type){86 var accept = this.header('Accept');8788 // Normalize extensions ".json" -> "json"89 if (type && '.' == type[0]) type = type.substr(1);88 if (!accept || accept === '*/*') {9091 // When Accept does not exist, or is '*/*' return true 92 if (!accept || '*/*' == accept) {93 return true;94 } else if (type) {95 // Allow "html" vs "text/html" etc96 if (type.indexOf('/') < 0) {
180 unmodified lines