aboutsummaryrefslogtreecommitdiff
path: root/mediawiki.lrdevplugin/MediaWikiExportServiceProvider.lua
diff options
context:
space:
mode:
authorRobin Krahl <me@robin-krahl.de>2015-06-27 19:29:11 +0200
committerRobin Krahl <me@robin-krahl.de>2015-06-27 19:29:11 +0200
commitd3ba117b246a5e6e21c93b94cd40ae460d2d3541 (patch)
tree555efe0c568ff1542711b1d575c2f395229c8515 /mediawiki.lrdevplugin/MediaWikiExportServiceProvider.lua
parent3c028a07fd88db17f94da3c54e9b6f4594e1636a (diff)
downloadLrMediaWiki-d3ba117b246a5e6e21c93b94cd40ae460d2d3541.tar.gz
LrMediaWiki-d3ba117b246a5e6e21c93b94cd40ae460d2d3541.tar.bz2
Add logging support and fix refactoring errors.
The user now may enable logging in MediaWikiUtils. If logging is enabled, a log file is written to the user’s "My Documents" that contains all API requests. Furthermore, bugs introduced by the refactoring in commit 8862341672dc288596d6ef66f92751bba6dfef25 have been fixed. - set up logging in MediaWikiUtils - write to the log in MediaWikiApi.performRequest - fix error in MediaWikiExportServiceProvider.processRenderedPhotos - fix error in MediaWikiApi.parseXmlDom Fix #43.
Diffstat (limited to 'mediawiki.lrdevplugin/MediaWikiExportServiceProvider.lua')
-rwxr-xr-xmediawiki.lrdevplugin/MediaWikiExportServiceProvider.lua3
1 files changed, 1 insertions, 2 deletions
diff --git a/mediawiki.lrdevplugin/MediaWikiExportServiceProvider.lua b/mediawiki.lrdevplugin/MediaWikiExportServiceProvider.lua
index 8405cea..accbf88 100755
--- a/mediawiki.lrdevplugin/MediaWikiExportServiceProvider.lua
+++ b/mediawiki.lrdevplugin/MediaWikiExportServiceProvider.lua
@@ -60,8 +60,7 @@ MediaWikiExportServiceProvider.processRenderedPhotos = function(functionContext,
MediaWikiInterface.prepareUpload(exportSettings.username, exportSettings.password, exportSettings.api_path)
-- iterate over photos
- for item in exportContext:renditions() do
- local rendition = item[1]
+ for i, rendition in exportContext:renditions() do
-- render photo
local success, pathOrMessage = rendition:waitForRender()
if success then