From: Michael Orlitzky Date: Fri, 10 Jan 2014 04:59:38 +0000 (-0500) Subject: Begin validating the XML. X-Git-Tag: 0.0.1~107 X-Git-Url: https://gitweb.michael.orlitzky.com/?a=commitdiff_plain;h=3b91dab2cc716aac332368e707f4ed27f059838a;p=dead%2Fhtsn-import.git Begin validating the XML. Fix a bug in the Injuries pickling. --- diff --git a/src/TSN/XML/Injuries.hs b/src/TSN/XML/Injuries.hs index bea54d3..f425f89 100644 --- a/src/TSN/XML/Injuries.hs +++ b/src/TSN/XML/Injuries.hs @@ -96,7 +96,7 @@ pickle_injuries_team :: PU InjuriesTeam pickle_injuries_team = xpElem "team" $ xpWrap (from_tuple, to_tuple) $ - xpPair xpText (xpAttr "league" (xpOption xpText)) + xpPair xpText (xpOption $ xpAttr "league" xpText) where from_tuple = uncurryN InjuriesTeam to_tuple m = (team_name m, team_league m) diff --git a/src/Xml.hs b/src/Xml.hs index e98e4b1..7f641b2 100644 --- a/src/Xml.hs +++ b/src/Xml.hs @@ -79,8 +79,7 @@ parse_opts :: SysConfigList parse_opts = [ withPreserveComment no, withRemoveWS yes, - withSubstDTDEntities no, - withValidate no ] + withSubstDTDEntities no ] -- | Given a root element name and a file path, return both the