Merge branch 'master' of github.com:visionmedia/express
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 · parents a7ca381, 8959ff1 · Browse files · 5 files·+10 added−20 removed
This commit
State
Before adoption: this commit came in with the history the project adopted, so no landing records it.
Diff stats
5 files+10 added−20 removed
- other:+10 added−20 removed
Provenance
- Commit
2d49c0d- Tree
8151354- Author
TJ Holowaychuk <tj@vision-media.ca>- Committer
TJ Holowaychuk <tj@vision-media.ca>- Parent 1
a7ca381- Parent 2
8959ff1
5 files changed+10 added−20 removed
modified:lib/router/index.js+2 added-4 removed
3 unmodified lines4 5 var Route = require('./route')6 , utils = require('../utils')7 , debug = require('debug')('express:router')8- , parse = require('connect').utils.parseUrl9- , methods = require('methods');8+ , parse = require('connect').utils.parseUrl;9 10 /**11 * Expose `Router` constructor.12 */78 unmodified lines91 , paramIndex = 092 , paramVal93 , route94 , keys96- , key97- , ret;95+ , key;96 97 // match next route98 function nextRoute(err) {99 pass(req._route_index + 1, err);157 unmodified linesmodified:lib/application.js+3 added-7 removed
7 unmodified lines8 , middleware = require('./middleware')9 , debug = require('debug')('express:application')10 , locals = require('./utils').locals11 , View = require('./view')12- , url = require('url')12 , utils = connect.utils13 , path = require('path')14 , http = require('http')16- , join = path.join17- , fs = require('fs');15+ , join = path.join;16 17 /**18 * Application prototype.19 */10 unmodified lines30 * @api private31 */32 33 app.init = function(){36- var self = this;34 this.cache = {};35 this.settings = {};36 this.engines = {};37 this.viewCallbacks = [];64 unmodified lines102 * @api public103 */104 105 app.use = function(route, fn){109- var app, home, handle;106+ var app, handle;107 108 // default route to '/'109 if ('string' != typeof route) fn = route, route = '/';110 340 unmodified lines451 * @api public452 */453 454 app.render = function(name, options, fn){458- var self = this459- , opts = {}455+ var opts = {}456 , cache = this.cache457 , engines = this.engines458 , view;459 73 unmodified linesmodified:lib/response.js+2 added-4 removed
1 /**2 * Module dependencies.3 */4 5-var fs = require('fs')6- , http = require('http')5+var http = require('http')6 , path = require('path')7 , connect = require('connect')8 , utils = connect.utils9 , sign = require('cookie-signature').sign3 unmodified lines13 , statusCodes = http.STATUS_CODES14 , send = connect.static.send15 , cookie = require('cookie')16 , send = require('send')18- , crc = require('crc')17 , mime = connect.mime18 , basename = path.basename19 , extname = path.extname20 , join = path.join;692 unmodified lines713 };714 715 // render716 app.render(view, options, fn);719-};717+};modified:support/app.js+1 added-3 removed
14 unmodified lines1516171819201920212239 unmodified lines62636465686614 unmodified linesapp.set('views', __dirname + '/views');app.set('view engine', 'jade');app.locals.self = true;
var repo = require('../package.json');
app.get('/render', function(req, res){ res.render('hello');});
39 unmodified linesapp.get('/match', function(req, res){ res.send('Hello World\n');});
app.listen(8000);No newline at end of fileapp.listen(8000);modified:Readme.md+2 added-2 removed
105 unmodified lines106 182 TJ Holowaychuk 5.1%107 54 Aaron Heckmann 1.5%108 34 csausdev 1.0%109 26 ciaranj 0.7%110- 21 Robert Sköld 0.6%110+ 21 Robert Sköld 0.6%111 6 Guillermo Rauch 0.2%112 3 Dav Glass 0.1%113 3 Nick Poulden 0.1%114 2 Randy Merrill 0.1%37 unmodified lines152 1 Jonathan Palardy 0.0%153 1 Jonathan Zacsh 0.0%154 1 Justin Lilly 0.0%155 1 Ken Sato 0.0%156- 1 Maciej Małecki 0.0%156+ 1 Maciej Małecki 0.0%157 1 Masahiro Hayashi 0.0%158 ```159 160 ## License 23 unmodified lines