Content deleted Content added
misc cleanup |
more cleanup |
||
Line 56:
local e = mw.ustring.sub(num,1,pr)
-- Hack to move to center of square: append a 5 to northings and eastings
if shift then
n = n.."5"
e = e.."5"
Line 274 ⟶ 275:
local function empty(s)
return not s
end
Line 281 ⟶ 282:
ngr, _ = mw.ustring.gsub(mw.ustring.upper(ngr),"[%s%p]","")
local first, last, lett, num = mw.ustring.find(ngr,"^([A-Z]+)(%d+)$")
if not first
return {err="Malformed NGR"}
end
Line 307 ⟶ 308:
local function alldigits(s)
return not mw.ustring.find(s,"%D")
end
Line 315 ⟶ 316:
local html = preview._warning({ msg })
if namespace == 0 and errmsg
html = html..'[[Category:Pages with malformed OS coordinates]]'
end
|