added switch case in clienthandler