presence: aggregate device updates
This commit is contained in:
@@ -23,7 +23,13 @@ pub(crate) async fn set_presence_route(
|
||||
|
||||
services
|
||||
.presence
|
||||
.set_presence(body.sender_user(), &body.presence, None, None, body.status_msg.clone())
|
||||
.set_presence_for_device(
|
||||
body.sender_user(),
|
||||
body.sender_device.as_deref(),
|
||||
&body.presence,
|
||||
body.status_msg.clone(),
|
||||
PresenceUpdateReason::ClientRequest,
|
||||
)
|
||||
.await?;
|
||||
|
||||
Ok(set_presence::v3::Response {})
|
||||
|
||||
@@ -268,11 +268,11 @@ async fn handle_edu_presence_update(
|
||||
|
||||
services
|
||||
.presence
|
||||
.set_presence(
|
||||
.set_presence_from_federation(
|
||||
&update.user_id,
|
||||
&update.presence,
|
||||
Some(update.currently_active),
|
||||
Some(update.last_active_ago),
|
||||
update.currently_active,
|
||||
update.last_active_ago,
|
||||
update.status_msg.clone(),
|
||||
)
|
||||
.await
|
||||
|
||||
Reference in New Issue
Block a user