I'm nervous about filtering things that are provided as buffers.

In the stream code on the node side, the `encoding` parameter is ignored if `chunk` is a buffer: https://github.com/joyent/node/blob/master/lib/_stream_writable.js#L179

So, if the user mistakenly did something like specify an encoding of "binary" this would write something totally different to the stream than if it weren't filtered (because it would be converted to a string of utf8 0s and 1s using this code, whereas without the filter, the param would be ignored and binary data would be written).

I think we're trying to be too clever here. I think we should have a function that _only_ filters if the chunk is a string (and document as such). The "encoding" parameter should be passed exactly as is to the eventual write function. The encoding parameter is about how to turn the javascript string into binary data. It is *not* about how the chunk is currently encoded.