fix inverted logic in bridge::connect