cleaned up client.rb