Fix error iterating nil object when mapping functions to line numbers (#320)
This commit is contained in:
parent
f97850dee6
commit
794fd0e14e
2
ldoc.lua
2
ldoc.lua
|
@ -573,12 +573,14 @@ if ldoc.prettify_files then
|
|||
for F in file_list:iter() do
|
||||
files:append(F.filename)
|
||||
local mod = F.modules[1]
|
||||
if mod then
|
||||
local ls = List()
|
||||
for item in mod.items:iter() do
|
||||
ls:append(item.lineno)
|
||||
end
|
||||
linemap[F.filename] = ls
|
||||
end
|
||||
end
|
||||
|
||||
if type(ldoc.prettify_files) == 'table' then
|
||||
files = tools.expand_file_list(ldoc.prettify_files, '*.*')
|
||||
|
|
Loading…
Reference in New Issue