Changed flush for node 0.10.0.

Changed the flush to be node 0.10.0 compatible.