Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

(minor) whitespace fixing

  • Loading branch information...
commit 75b9db3a8377060ce9763cd6579f96e943b33cb8 1 parent b382f0d
@cloudhead authored
Showing with 11 additions and 11 deletions.
  1. +11 −11 lib/journey.js
View
22 lib/journey.js
@@ -209,10 +209,10 @@ journey.Router.prototype = {
var match = (function (pattern) {
var path = request.url.pathname;
- if (! path) { return new(BadRequest) }
+ if (! path) { return new(BadRequest) }
- return (path.length > 1 ? path.slice(1) : path).match(pattern);
- })(route.pattern);
+ return (path.length > 1 ? path.slice(1) : path).match(pattern);
+ })(route.pattern);
//
// Return here if no match to avoid potentially expensive
@@ -308,20 +308,20 @@ journey.Router.prototype = {
// It creates a new `route` context, in which the response will be generated.
dispatch: function (request, body, respond) {
var route, parser, that = this,
- params = querystring.parse(request.url.query || null);
+ params = querystring.parse(request.url.query || null);
if (! this.verifyHeaders(request)) {
return respond(new(NotAcceptable)(request.headers.accept));
}
this.resolve(request, body, function (err, resolved) {
- if (err) {
- if (err.status) { // If it's an HTTP Error
- return respond({
- headers: err.headers || {},
- status: err.status,
- body: JSON.stringify(err.body)
- });
+ if (err) {
+ if (err.status) { // If it's an HTTP Error
+ return respond({
+ headers: err.headers || {},
+ status: err.status,
+ body: JSON.stringify(err.body)
+ });
} else {
throw err;
}
Please sign in to comment.
Something went wrong with that request. Please try again.