- querylog: fix get data
Close #1589 Squashed commit of the following: commit 83d1d15f06a67746feb0e82fb71d5ea02f86ab69 Author: Simon Zolin <s.zolin@adguard.com> Date: Fri Apr 17 14:11:00 2020 +0300 - querylog: fix get data
This commit is contained in:
parent
e24e5741fe
commit
93a597fce4
|
@ -238,7 +238,7 @@ func (l *queryLog) getData(params getDataParams) map[string]interface{} {
|
|||
entries := append(memoryEntries, fileEntries...)
|
||||
if len(entries) > getDataLimit {
|
||||
// remove extra records
|
||||
entries = entries[(len(entries) - getDataLimit):]
|
||||
entries = entries[:getDataLimit]
|
||||
}
|
||||
if len(entries) == getDataLimit {
|
||||
// change the "oldest" value here.
|
||||
|
|
Loading…
Reference in New Issue