improve logging in client