Skip to content

Commit

Permalink
fix(deps): Upgrade connect 3.
Browse files Browse the repository at this point in the history
This means dropping support for node 0.8.

Fixes part of karma-runner#1410

Conflicts:
	package.json
  • Loading branch information
dignifiedquire authored and shirish87 committed Aug 29, 2015
1 parent 7a7ca4f commit 95a1c93
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 9 deletions.
1 change: 0 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
language: node_js
node_js:
- "0.10"
- "0.8"

env:
global:
Expand Down
2 changes: 1 addition & 1 deletion lib/middleware/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ var setNoCacheHeaders = function(response) {


var setHeavyCacheHeaders = function(response) {
response.setHeader('Cache-Control', ['public', 'max-age=31536000']);
response.setHeader('Cache-Control', 'public, max-age=31536000');
};


Expand Down
2 changes: 1 addition & 1 deletion lib/middleware/runner.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ var path = require('path');
var helper = require('../helper');
var log = require('../logger').create();
var constant = require('../constants');
var json = require('connect').json();
var json = require('body-parser').json();

// TODO(vojta): disable when single-run mode
var createRunnerMiddleware = function(emitter, fileList, capturedBrowsers, reporter, executor,
Expand Down
8 changes: 2 additions & 6 deletions lib/middleware/source_files.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

var querystring = require('querystring');
var common = require('./common');
var pause = require('connect').utils.pause;


var findByPath = function(files, path) {
Expand All @@ -28,10 +27,7 @@ var createSourceFilesMiddleware = function(filesPromise, serveFile,
.replace(/^\/absolute/, '')
.replace(/^\/base/, basePath);

// Need to pause the request because of proxying, see:
// https://groups.google.com/forum/#!topic/q-continuum/xr8znxc_K5E/discussion
// TODO(vojta): remove once we don't care about Node 0.8
var pausedRequest = pause(request);
request.pause();

return filesPromise.then(function(files) {
// TODO(vojta): change served to be a map rather then an array
Expand All @@ -51,7 +47,7 @@ var createSourceFilesMiddleware = function(filesPromise, serveFile,
next();
}

pausedRequest.resume();
request.resume();
});
};
};
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,7 @@
"Jeff Froom <[email protected]>"
],
"dependencies": {
"body-parser": "~1.12.4",
"di": "~0.0.1",
"socket.io": "~1.3.6",
"chokidar": ">=0.8.2",
Expand Down

0 comments on commit 95a1c93

Please sign in to comment.