Permalink
Browse files

all tests pass for url rewriting

  • Loading branch information...
1 parent c7b95e2 commit a2a10b7324a452325fd7e2743c5a524a03d32ea8 @substack committed Jan 15, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/update_url.js
View
@@ -6,7 +6,7 @@ module.exports = function (bufs, url) {
var after = bufs[jx[0]].slice(jx[1]);
var middle = Buffer.isBuffer(url) ? url : new Buffer(url);
- bufs.splice(ix[0], jx[0] + 1, before, middle, after);
+ bufs.splice(ix[0], jx[0] - ix[0] + 1, before, middle, after);
return jx[2] - middle.length;
};

0 comments on commit a2a10b7

Please sign in to comment.