added server handler for client