cleaned up connection.rkt and added contracts