simple flow control for node-style callbacks