fixd bugs from client