fix a bug in client side