@@ -211,10 +211,10 @@ writeDocx opts doc@(Pandoc meta _) = do
211211 let doc' = stripInvalidChars . walk fixDisplayMath $ doc
212212 username <- lookup "USERNAME" <$> getEnvironment
213213 utctime <- getCurrentTime
214− distArchive <- getDefaultReferenceDocx datadir
214+ distArchive <- getDefaultReferenceDocx Nothing
215215 refArchive <- case writerReferenceDocx opts of
216216 Just f -> liftM (toArchive . toLazy) $ B.readFile f
217− Nothing -> return distArchive
217+ Nothing -> getDefaultReferenceDocx datadir
218218
219219 parsedDoc <- parseXml refArchive distArchive "word/document.xml"
220220 let wname f qn = qPrefix qn == Just "w" && f (qName qn)