Module:Mapframe: Difference between revisions

Undo revision 398775 by WikiDwarf (talk)
No edit summary
Tag: Reverted
(Undo revision 398775 by WikiDwarf (talk))
Tag: Undo
 
Line 759: Line 759:
if util.getParameterValue(args, 'frameLongitude') then
if util.getParameterValue(args, 'frameLongitude') then
attribs.longitude = util.getParameterValue(args, 'frameLongitude')
attribs.longitude = util.getParameterValue(args, 'frameLongitude')
end
end
if not attribs.latitude and not attribs.longitude and not coordsDerivedFromFeatures then
local success, lat, long = pcall(util.wikidataCoords, util.getParameterValue(args, 'id') or mw.wikibase.getEntityIdForCurrentPage())
if success then
attribs.latitude = tostring(lat)
attribs.longitude = tostring(long)
end
end
end
end