Content deleted Content added
Implementing ru name |
Testing |
||
Line 233:
}
if(p.isOnlyName(fullNameTable)) then
local connectors = {"de", "del", "el", "la", "los", "las", "y"}▼
end
for n, name in ipairs(fullNameTable) do▼
local firstSurname = 0
for k, connector in ipairs(connectors) do▼
local lastSurname = 0
if (name == connector) then▼
table.insert(name.familyNames, actualName)
▲ table.remove(fullNameTable, n+1)
if(connector == actualName) then
▲ else
firstSurname = d
▲ if(shouldJoinNext and #fullNameTable-1 >= n) then
-- This means the two surnames are compound.
▲ for k, preposition in ipairs(prepositions) do
table.insert(name.familyNames, table.concat(fullNameTable, " ", d, z-1))
table.insert(name.familyNames, table.concat(fullNameTable, " ", z))
end
end
if(lastSurname==0) then
-- This means only one is compound or just one is given.
for article in ipairs(articles)do
if(article==name and d+1 == #fullNameTable) then
table.insert(name.familyNames, table.concat(fullNameTable, " ", d))
else
table.insert(name.familyNames, table.concat(fullNameTable, " ", d, #fullNameTable-1))
end
end
Line 256 ⟶ 266:
end
end
table.insert(name.givenNames, actualName)
end
end
|