Docx writer: Fixed error message when style file can't be parsed.
This commit is contained in:
parent
8d4680bbfe
commit
e6e63d1699
1 changed files with 2 additions and 1 deletions
|
@ -146,7 +146,8 @@ writeDocx mbRefDocx opts doc@(Pandoc (Meta tit auths date) _) = do
|
|||
let styledoc = case findEntryByPath stylepath refArchive >>=
|
||||
parseXMLDoc . toString . fromEntry of
|
||||
Just d -> d
|
||||
Nothing -> error $ stylepath ++ "missing in reference docx"
|
||||
Nothing -> error $ "Unable to parse " ++ stylepath ++
|
||||
" from reference.docx"
|
||||
let styledoc' = styledoc{ elContent = elContent styledoc ++ map Elem newstyles }
|
||||
let styleEntry = toEntry stylepath epochtime $ fromString $ showTopElement' styledoc'
|
||||
-- construct word/numbering.xml
|
||||
|
|
Loading…
Add table
Reference in a new issue