Clean up and simplify client