diff --git a/AGHTechDoc.md b/AGHTechDoc.md index b2f4ab73..ad9854d3 100644 --- a/AGHTechDoc.md +++ b/AGHTechDoc.md @@ -1302,6 +1302,8 @@ Response: The most recent entries are at the top of list. +If there are no more older entries, `"oldest":""` is returned. + ### API: Set querylog parameters diff --git a/querylog/querylog_search.go b/querylog/querylog_search.go index eda1f92d..afa8afc2 100644 --- a/querylog/querylog_search.go +++ b/querylog/querylog_search.go @@ -129,7 +129,9 @@ func (l *queryLog) searchFiles(params *searchParams) ([]*logEntry, time.Time, in } } - oldest = time.Unix(0, oldestNano) + if oldestNano != 0 { + oldest = time.Unix(0, oldestNano) + } return entries, oldest, total }