A couple refactors in Client