fix: Make tests pass again

This commit is contained in:
TJ DeVries
2020-09-17 21:51:14 -04:00
parent 93369e1488
commit f3fc1ca8c1
3 changed files with 31 additions and 32 deletions

View File

@@ -671,8 +671,6 @@ pickers.entry_manager = function(max_results, set_entry)
return setmetatable({
add_entry = function(self, score, entry)
assert(type(entry) == "table", "entry must be a table by the time it reaches here")
score = score or 0
for index, item in ipairs(entry_state) do
@@ -727,6 +725,10 @@ pickers.entry_manager = function(max_results, set_entry)
return (entry_state[index] or {}).entry
end,
get_score = function(_, index)
return (entry_state[index] or {}).score
end,
find_entry = function(_, entry)
if entry == nil then
return nil