Made minor updates to connection initialization