Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

fix file-serving bug

  • Loading branch information...
commit d8393366f85553fadad82a699f33650d726d4acf 1 parent a1c05e5
@cloudhead authored
Showing with 3 additions and 3 deletions.
  1. +2 −2 lib/node-static.js
  2. +1 −1  package.json
View
4 lib/node-static.js
@@ -6,7 +6,7 @@ var fs = require('fs'),
url = require('url'),
path = require('path');
-this.version = [0, 5, 5];
+this.version = [0, 5, 6];
var mime = require('./node-static/mime');
var util = require('./node-static/util');
@@ -226,7 +226,7 @@ this.Server.prototype.respond = function (pathname, status, _headers, files, sta
this.Server.prototype.stream = function (pathname, files, buffer, res, callback) {
(function streamFile(files, offset) {
- var file = files.shift(), path;
+ var file = files.shift();
if (file) {
file = file[0] === '/' ? file : path.join(pathname || '.', file);
View
2  package.json
@@ -9,7 +9,7 @@
"dependencies" : [],
"lib" : "lib",
"main" : "./lib/node-static",
- "version" : "0.5.5",
+ "version" : "0.5.6",
"directories" : { "test": "./test" },
"engines" : { "node": ">= 0.4.1" }
}
Please sign in to comment.
Something went wrong with that request. Please try again.