mirror of
https://github.com/appgurueu/modlib.git
synced 2024-11-21 23:03:44 +01:00
Fix hashlist:pop_head
This commit is contained in:
parent
c2cfd59426
commit
a89ce5bca8
@ -84,6 +84,7 @@ end
|
|||||||
function list:pop_head()
|
function list:pop_head()
|
||||||
if self.length == 0 then return end
|
if self.length == 0 then return end
|
||||||
local value = self:get_head()
|
local value = self:get_head()
|
||||||
|
self.length = self.length - 1
|
||||||
self.head = self.head + 1
|
self.head = self.head + 1
|
||||||
self[self.head] = nil
|
self[self.head] = nil
|
||||||
return value
|
return value
|
||||||
|
Loading…
Reference in New Issue
Block a user