A node.js stream that stops piping when a pattern is reached