update leave to use connections