mirror of
https://github.com/stoatchat/stoatchat.git
synced 2026-07-14 13:36:59 +00:00
Use $lt and $gt instead of $lte and $gte.
This commit is contained in:
@@ -503,11 +503,11 @@ pub fn messages(
|
||||
let mut query = doc! { "channel": target.id };
|
||||
|
||||
if let Some(before) = &options.before {
|
||||
query.insert("_id", doc! { "$lte": before });
|
||||
query.insert("_id", doc! { "$lt": before });
|
||||
}
|
||||
|
||||
if let Some(after) = &options.after {
|
||||
query.insert("_id", doc! { "$gte": after });
|
||||
query.insert("_id", doc! { "$gt": after });
|
||||
}
|
||||
|
||||
let limit = if let Some(limit) = options.limit {
|
||||
|
||||
Reference in New Issue
Block a user