aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Text/Pandoc/Citeproc.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Citeproc.hs b/src/Text/Pandoc/Citeproc.hs
index ca1ab9f96..e87ddcbcd 100644
--- a/src/Text/Pandoc/Citeproc.hs
+++ b/src/Text/Pandoc/Citeproc.hs
@@ -507,7 +507,9 @@ linkifyVariables ref =
x'' = if "://" `T.isInfixOf` x'
then x'
else pref <> x'
- in FancyVal (B.link x'' "" (B.str x'))
+ in if T.null x'
+ then x
+ else FancyVal (B.link x'' "" (B.str x'))
extractText :: Val Inlines -> Text
extractText (TextVal x) = x