fix duplicate connect