Module:Sandbox/Jackmcbarn: Difference between revisions

Content deleted Content added
Jackmcbarn (talk | contribs)
handle first names too
Jackmcbarn (talk | contribs)
don't double-index
Line 15:
local listEntries = split(list, '\n')
table.sort(listEntries, function(a,b)
local aWords, bWords = split(a, ' ')[2], split(b, ' ')[2]
return (aWords[2] .. aWords[1]) < (bWords[2] .. bWords[1])
end)