deconstructor for Client.cs