[OSM-dev] Code review for Lua requested

Andrew Hain andrewhainosm at hotmail.co.uk
Fri Sep 7 21:58:47 UTC 2018

I would like a second opinion on some Lua code I am writing for the OSM wiki.

The template {{langcode}} is called frequently within pages to detemine the language of pages from the name and is complicated. Calls with arguments have been added to several templates [ https://wiki.openstreetmap.org/w/index.php?title=Template:Available_languages&diff=1573804&oldid=1573466 ]; the argument makes Mediawiki not cache the template and sometimes chokes the page renderer [ https://wiki.openstreetmap.org/wiki/Zh-hant:Map_Features ].

The pages https://wiki.openstreetmap.org/wiki/User:Wynndale/langcode and https://wiki.openstreetmap.org/wiki/Module:Sandbox/Wynndale are a streamlined version of this template. I could do with another pair of eyes.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/dev/attachments/20180907/244b919b/attachment.html>

More information about the dev mailing list