mirror of
https://github.com/mikedilger/gossip.git
synced 2024-09-19 19:46:50 +00:00
bugfix
This commit is contained in:
parent
bd0548f19c
commit
daac5124bf
@ -52,6 +52,10 @@ impl DbEvent {
|
|||||||
}
|
}
|
||||||
|
|
||||||
pub async fn fetch_by_ids(ids: Vec<IdHex>) -> Result<Vec<DbEvent>, Error> {
|
pub async fn fetch_by_ids(ids: Vec<IdHex>) -> Result<Vec<DbEvent>, Error> {
|
||||||
|
if ids.is_empty() {
|
||||||
|
return Ok(vec![]);
|
||||||
|
}
|
||||||
|
|
||||||
let sql = format!(
|
let sql = format!(
|
||||||
"SELECT id, raw, pubkey, created_at, kind, content, ots FROM event WHERE id IN ({})",
|
"SELECT id, raw, pubkey, created_at, kind, content, ots FROM event WHERE id IN ({})",
|
||||||
repeat_vars(ids.len())
|
repeat_vars(ids.len())
|
||||||
|
Loading…
Reference in New Issue
Block a user