mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-09 05:39:12 +00:00
Only use chat messages count in history API endpoint when set by client
This commit is contained in:
@@ -114,7 +114,7 @@ def chat_history(
|
|||||||
if n > 0:
|
if n > 0:
|
||||||
meta_log["chat"] = meta_log["chat"][-n:]
|
meta_log["chat"] = meta_log["chat"][-n:]
|
||||||
# Else return all messages except latest N
|
# Else return all messages except latest N
|
||||||
else:
|
elif n < 0:
|
||||||
meta_log["chat"] = meta_log["chat"][:n]
|
meta_log["chat"] = meta_log["chat"][:n]
|
||||||
|
|
||||||
update_telemetry_state(
|
update_telemetry_state(
|
||||||
|
|||||||
Reference in New Issue
Block a user