Adding a connection event in the client