Difference between revisions of "Module:Template translation"

m
why did I delete the translation existence test ??? Sorry
>Verdy p
m
>Verdy p
m (why did I delete the translation existence test ??? Sorry)
Line 44: Line 44:
     if (subpage ~= '')
     if (subpage ~= '')
     then
     then
         langcode = subpage
         local translation = mw.title.new(namespace .. template .. '/' .. subpage)
        if (translation.id ~= 0)
        then
            langcode = subpage
        end
     end
     end
     -- Copy args pseudo-table to a proper table so we can feed it to expandTemplate
     -- Copy args pseudo-table to a proper table so we can feed it to expandTemplate
Anonymous user