add remove connection function