mirror of
https://github.com/stoatchat/stoatchat.git
synced 2026-07-14 21:47:02 +00:00
fix: ensure limit is always at least 1 when sent to database
This commit is contained in:
@@ -95,7 +95,7 @@ impl AbstractMessages for MongoDb {
|
||||
COL,
|
||||
older_message_filter,
|
||||
FindOptions::builder()
|
||||
.limit(limit / 2)
|
||||
.limit(limit / 2 + 1)
|
||||
.sort(doc! {
|
||||
"_id": -1_i32
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user