Split handleData from addData
Split handleData from addData

This reduces the complexity of the addData function slightly and makes
it behave more like a method of StreamState.  Although it isn't (and
can't be) a method of StreamState, we will make it a method of
InternalStreamState if we later create such a class (which would be a
good idea).

Note:  I'm on the fence about switching `state` to `this` to placate
ESLint.  It does convey the intention better, but it is unconventional
and a bit tricky.

Signed-off-by: Kevin Locke <ffb4761cba839470133bee36aeb139f58d7dbaa9@kevinlocke.name>

kevinoid/stream-compare,kevinoid/stream-compare,kevinoid/stream-compare