Fixed up various client bugs