xml2json update for function

minimized the text necessary to parse a function back into a function.