refactors more of the base connection get code