fixed missing frontload on read
This commit is contained in:
parent
d74924992a
commit
b6cf5f2665
1 changed files with 1 additions and 0 deletions
|
@ -48,6 +48,7 @@ func newNodeCache(size int) *nodeCache {
|
|||
func (nc *nodeCache) Get(key string) *Node {
|
||||
element := nc.elements[key]
|
||||
if element != nil {
|
||||
nc.data.MoveToFront(element)
|
||||
return element.Value.(nodeCacheLeaf).node
|
||||
}
|
||||
return nil
|
||||
|
|
Loading…
Reference in a new issue