FileManagerHistory: fix loop error

pull/2586/head
Frans de Jonge 7 years ago committed by Qingping Hou
parent 2c80ff7d7b
commit 827e77afbe

@ -47,6 +47,11 @@ function ReadHistory:_indexing(start)
end
function ReadHistory:_sort()
for i = #self.hist, 1, -1 do
if self.hist[i].file == nil then
table.remove(self.hist, i)
end
end
table.sort(self.hist, fileFirstOrdering)
-- TODO(zijiehe): Use binary insert instead of a loop to deduplicate.
for i = #self.hist, 2, -1 do

Loading…
Cancel
Save