aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Readers/Org/Inlines.hs
diff options
context:
space:
mode:
authorAlbert Krewinkel <albert@zeitkraut.de>2020-06-30 22:19:46 +0200
committerAlbert Krewinkel <albert@zeitkraut.de>2020-06-30 22:30:15 +0200
commitd6711bd7d98d69541e8617236c2f2c358dd67307 (patch)
tree284696635cac3833311d5db277bf64c317eb0674 /src/Text/Pandoc/Readers/Org/Inlines.hs
parentefbc2050315b60c8a753dee6255465f1083019ab (diff)
downloadpandoc-d6711bd7d98d69541e8617236c2f2c358dd67307.tar.gz
Org reader: respect export setting disabling footnotes
Footnotes can be removed from the final document with the `#+OPTION: f:nil` export setting.
Diffstat (limited to 'src/Text/Pandoc/Readers/Org/Inlines.hs')
-rw-r--r--src/Text/Pandoc/Readers/Org/Inlines.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Readers/Org/Inlines.hs b/src/Text/Pandoc/Readers/Org/Inlines.hs
index 13b1315b8..b234bee58 100644
--- a/src/Text/Pandoc/Readers/Org/Inlines.hs
+++ b/src/Text/Pandoc/Readers/Org/Inlines.hs
@@ -378,7 +378,10 @@ citation = try $ do
else rest
footnote :: PandocMonad m => OrgParser m (F Inlines)
-footnote = try $ inlineNote <|> referencedNote
+footnote = try $ do
+ note <- inlineNote <|> referencedNote
+ withNote <- getExportSetting exportWithFootnotes
+ return $ if withNote then note else mempty
inlineNote :: PandocMonad m => OrgParser m (F Inlines)
inlineNote = try $ do