Update webserver.js

Tighten code around sending xml data