diff --git a/lm2.go b/lm2.go index 4bca1e6..c8c0df3 100644 --- a/lm2.go +++ b/lm2.go @@ -167,7 +167,7 @@ func (c *Collection) readRecord(offset int64) (*record, error) { } c.stats.incRecordsRead(1) c.stats.incCacheMisses(1) - + c.cache.push(rec) return rec, nil } @@ -183,9 +183,6 @@ func (c *Collection) nextRecord(rec *record, level int) (*record, error) { if err != nil { return nil, err } - if level >= 2 { - c.cache.push(rec) - } return nextRec, nil }