refactoring out the need for an explicit connect