fixed up client and server