summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/biblatex-ext/biblatex-ext-oa-doiapi.sty
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2019-01-11 22:28:35 +0000
committerKarl Berry <karl@freefriends.org>2019-01-11 22:28:35 +0000
commit69f4dc372985a82d9d1e813dfb2762422205dcea (patch)
treea67edbcb2cd507f19db56a2c630441149722c85f /Master/texmf-dist/tex/latex/biblatex-ext/biblatex-ext-oa-doiapi.sty
parent9cfb1de8ef3132928352665eba3feb20fd50ce2f (diff)
biblatex-ext (11jan19)
git-svn-id: svn://tug.org/texlive/trunk@49671 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/biblatex-ext/biblatex-ext-oa-doiapi.sty')
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-ext/biblatex-ext-oa-doiapi.sty10
1 files changed, 6 insertions, 4 deletions
diff --git a/Master/texmf-dist/tex/latex/biblatex-ext/biblatex-ext-oa-doiapi.sty b/Master/texmf-dist/tex/latex/biblatex-ext/biblatex-ext-oa-doiapi.sty
index 358814a8e86..dac9c61d859 100644
--- a/Master/texmf-dist/tex/latex/biblatex-ext/biblatex-ext-oa-doiapi.sty
+++ b/Master/texmf-dist/tex/latex/biblatex-ext/biblatex-ext-oa-doiapi.sty
@@ -1,5 +1,5 @@
\ProvidesPackage{biblatex-ext-oa-doiapi}
- [2019/01/04 v0.6a Obtain open access information from DOI via unpaywall.org
+ [2019/01/11 v0.6b Obtain open access information from DOI via unpaywall.org
and doi.org (MW)]
\RequirePackage{etoolbox}
@@ -34,7 +34,11 @@
\def\extblx@oa@api@luastring#1{"\luaescapestring{#1}"}
\def\extblx@oa@api@luastringN#1{\extblx@oa@api@luastring{\unexpanded{#1}}}
-% The oai file should contain a Lua table with the relevant OA data
+% no local here, since that would restrict the assignment to
+% this \directlua only, that would be too local
+\directlua{blxextdoiapi = require("blxextdoiapi")}
+
+% The oai file should contain a (global!) Lua table with the relevant OA data
\IfFileExists{\jobname.oai}
{\extblx@oa@api@info@noline{%
Load OA database from\MessageBreak
@@ -44,8 +48,6 @@
No OA database file present at\MessageBreak
\jobname.oai}}
-\directlua{require("blxextdoiapi")}
-
\newcommand*{\SetDOIAPIMail}[1]{%
\cslet{extblx@oa@api@mailset}\@empty
\directlua{