Remove waitFlush parameter. Fixes #34. Also fixes a minor bug where the wrong service was being returned.