Module:Coordinates: Difference between revisions
From Roses, Tulips, & Liberty
Content added Content deleted
m (1 revision imported: Wikipedia) |
(per request) |
||
Line 490: | Line 490: | ||
local function makeWikidataCategories(qid) |
local function makeWikidataCategories(qid) |
||
local ret |
local ret |
||
local qid = qid or mw.wikibase.getEntityIdForCurrentPage() |
|||
if mw.wikibase and current_page.namespace == 0 then |
if mw.wikibase and current_page.namespace == 0 then |
||
if qid and mw.wikibase.entityExists(qid) and mw.wikibase.getBestStatements(qid, "P625") and mw.wikibase.getBestStatements(qid, "P625")[1] then |
|||
⚫ | |||
if entity and entity.claims and entity.claims.P625 and entity.claims.P625[1] then |
|||
⚫ | |||
if snaktype == 'value' then |
if snaktype == 'value' then |
||
-- coordinates exist both here and on Wikidata, and can be compared. |
-- coordinates exist both here and on Wikidata, and can be compared. |