mirror of
https://gitlab.computer.surgery/matrix/grapevine.git
synced 2025-12-17 15:51:23 +01:00
rename Ruma to Ar
This follows the pattern of the previous commit.
This commit is contained in:
parent
7ea98dac72
commit
f8961d5578
37 changed files with 183 additions and 181 deletions
|
|
@ -18,7 +18,7 @@ use ruma::{
|
|||
use serde_json::value::to_raw_value;
|
||||
use tracing::warn;
|
||||
|
||||
use crate::{service::pdu::PduBuilder, services, Error, Ra, Result, Ruma};
|
||||
use crate::{service::pdu::PduBuilder, services, Ar, Error, Ra, Result};
|
||||
|
||||
/// # `PUT /_matrix/client/r0/profile/{userId}/displayname`
|
||||
///
|
||||
|
|
@ -26,7 +26,7 @@ use crate::{service::pdu::PduBuilder, services, Error, Ra, Result, Ruma};
|
|||
///
|
||||
/// - Also makes sure other users receive the update using presence EDUs
|
||||
pub(crate) async fn set_displayname_route(
|
||||
body: Ruma<set_display_name::v3::Request>,
|
||||
body: Ar<set_display_name::v3::Request>,
|
||||
) -> Result<Ra<set_display_name::v3::Response>> {
|
||||
let sender_user = body.sender_user.as_ref().expect("user is authenticated");
|
||||
|
||||
|
|
@ -116,7 +116,7 @@ pub(crate) async fn set_displayname_route(
|
|||
///
|
||||
/// - If user is on another server: Fetches displayname over federation
|
||||
pub(crate) async fn get_displayname_route(
|
||||
body: Ruma<get_display_name::v3::Request>,
|
||||
body: Ar<get_display_name::v3::Request>,
|
||||
) -> Result<Ra<get_display_name::v3::Response>> {
|
||||
if body.user_id.server_name() != services().globals.server_name() {
|
||||
let response = services()
|
||||
|
|
@ -146,7 +146,7 @@ pub(crate) async fn get_displayname_route(
|
|||
///
|
||||
/// - Also makes sure other users receive the update using presence EDUs
|
||||
pub(crate) async fn set_avatar_url_route(
|
||||
body: Ruma<set_avatar_url::v3::Request>,
|
||||
body: Ar<set_avatar_url::v3::Request>,
|
||||
) -> Result<Ra<set_avatar_url::v3::Response>> {
|
||||
let sender_user = body.sender_user.as_ref().expect("user is authenticated");
|
||||
|
||||
|
|
@ -239,7 +239,7 @@ pub(crate) async fn set_avatar_url_route(
|
|||
/// - If user is on another server: Fetches `avatar_url` and `blurhash` over
|
||||
/// federation
|
||||
pub(crate) async fn get_avatar_url_route(
|
||||
body: Ruma<get_avatar_url::v3::Request>,
|
||||
body: Ar<get_avatar_url::v3::Request>,
|
||||
) -> Result<Ra<get_avatar_url::v3::Response>> {
|
||||
if body.user_id.server_name() != services().globals.server_name() {
|
||||
let response = services()
|
||||
|
|
@ -271,7 +271,7 @@ pub(crate) async fn get_avatar_url_route(
|
|||
///
|
||||
/// - If user is on another server: Fetches profile over federation
|
||||
pub(crate) async fn get_profile_route(
|
||||
body: Ruma<get_profile::v3::Request>,
|
||||
body: Ar<get_profile::v3::Request>,
|
||||
) -> Result<Ra<get_profile::v3::Response>> {
|
||||
if body.user_id.server_name() != services().globals.server_name() {
|
||||
let response = services()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue