[Pkg-javascript-commits] [node-stream-splicer] 15/71: fixed splicer test

Bastien Roucariès rouca at moszumanska.debian.org
Fri Dec 15 09:55:47 UTC 2017


This is an automated email from the git hooks/post-receive script.

rouca pushed a commit to branch master
in repository node-stream-splicer.

commit cfbee94725a8f37fe90a26323099b83e4de26231
Author: James Halliday <mail at substack.net>
Date:   Sun Jun 8 06:51:35 2014 -0700

    fixed splicer test
---
 index.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/index.js b/index.js
index 0c5e469..15feaf5 100644
--- a/index.js
+++ b/index.js
@@ -112,8 +112,8 @@ Pipeline.prototype.splice = function (start, removeLen) {
     var removed = this._streams.splice.apply(this._streams, arguments);
     var n = start < 0 ? this._streams.length - start : start;
     
-    if (this._streams[n] && removed.length > 0) {
-        this._streams[n].unpipe(removed[0]);
+    if (this._streams[n-1] && removed.length > 0) {
+        this._streams[n-1].unpipe(removed[0]);
     }
     for (var i = 1; i < removed.length; i++) {
         removed[i-1].unpipe(removed[i]);

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/node-stream-splicer.git



More information about the Pkg-javascript-commits mailing list