summaryrefslogtreecommitdiff
path: root/tex/context/base/trac-xml.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/trac-xml.lua')
-rw-r--r--tex/context/base/trac-xml.lua14
1 files changed, 7 insertions, 7 deletions
diff --git a/tex/context/base/trac-xml.lua b/tex/context/base/trac-xml.lua
index df213ba2d..7dd3969ef 100644
--- a/tex/context/base/trac-xml.lua
+++ b/tex/context/base/trac-xml.lua
@@ -138,16 +138,15 @@ function reporters.export(t,method,filename)
if not xmlfound(t) then
return exporthelp(t)
end
- dofile(resolvers.findfile("trac-exp.lua","tex"))
- if not exporters or not method then
- return exporthelp(t)
- end
if not method or method == "" then
- method = environment.argument["exporthelp"]
+ method = environment.arguments["exporthelp"]
end
if not filename or filename == "" then
filename = environment.files[1]
end
+ if not exporters or not method then
+ return exporthelp(t)
+ end
if method == "all" then
method = table.keys(exporters)
else
@@ -156,9 +155,10 @@ function reporters.export(t,method,filename)
if type(filename) ~= "string" or filename == "" then
filename = false
elseif file.pathpart(filename) == "" then
- t.report("export file %a will not be saved on the current path (safeguard)")
- filename = false
+ t.report("export file %a will not be saved on the current path (safeguard)",filename)
+ return
end
+ dofile(resolvers.findfile("trac-exp.lua","tex"))
for i=1,#method do
local m = method[i]
local result = exporters[m](t,m)