Fix a connection bug