From 09eb582b573129055fab1221c8aa2aed9f424e50 Mon Sep 17 00:00:00 2001 From: Jordan Eldredge Date: Thu, 13 Jun 2019 22:23:02 -0700 Subject: [PATCH] Use Utils.readXml --- experiments/modern/src/App.js | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/experiments/modern/src/App.js b/experiments/modern/src/App.js index 5237bcf7..42d68afd 100644 --- a/experiments/modern/src/App.js +++ b/experiments/modern/src/App.js @@ -12,14 +12,7 @@ async function getSkin() { ); const blob = await resp.blob(); const zip = await JSZip.loadAsync(blob); - - const player = Utils.getCaseInsensitveFile(zip, "xml/player-elements.xml"); - const xml = await player.async("text"); - - const elementsDoc = await xml2js(xml, { - compact: false, - elementsKey: "children", - }); + const elementsDoc = await Utils.readXml(zip, "xml/player-elements.xml"); const images = {}; // TODO: Clearly more complicated than it needed to be.