Ironing out some connection logic