also, dont start SendActivityTask for empty `to`, and remove
useless comment
Kind: Serialize,
<T as Extends<Kind>>::Error: From<serde_json::Error> + Send + Sync + 'static,
{
- if !Settings::get().federation.enabled {
+ if !Settings::get().federation.enabled || to.is_empty() {
return Ok(());
}
}
}
- let mut inboxes = vec![community.get_shared_inbox_url()?];
+ let mut inboxes: Vec<Url> = vec![];
+ if !community.local {
+ inboxes.push(community.get_shared_inbox_url()?);
+ }
inboxes.extend(mention_inboxes);
inboxes = inboxes.into_iter().unique().collect();
let timeout = Duration::from_secs(60);
- // speed up tests
- // before: 305s
- // after: 240s
let json = retry(|| {
client
.get(url.as_str())