Trying to fix message passing beetween client and server