Fix hashlist:pop_head

master
Lars Mueller 2021-12-27 20:09:26 +01:00
parent c2cfd59426
commit a89ce5bca8
1 changed files with 1 additions and 0 deletions

View File

@ -84,6 +84,7 @@ end
function list:pop_head()
if self.length == 0 then return end
local value = self:get_head()
self.length = self.length - 1
self.head = self.head + 1
self[self.head] = nil
return value