diff --git a/crates/ruma-client-api/src/r0/config/set_room_account_data.rs b/crates/ruma-client-api/src/r0/config/set_room_account_data.rs index f4e1f3ad..7faba5f8 100644 --- a/crates/ruma-client-api/src/r0/config/set_room_account_data.rs +++ b/crates/ruma-client-api/src/r0/config/set_room_account_data.rs @@ -19,7 +19,7 @@ ruma_api! { /// /// To create a `RawJsonValue`, use `serde_json::value::to_raw_value`. #[ruma_api(body)] - pub data: Box, + pub data: &'a RawJsonValue, /// The event type of the account_data to set. /// @@ -47,7 +47,7 @@ ruma_api! { impl<'a> Request<'a> { /// Creates a new `Request` with the given data, event type, room ID and user ID. pub fn new( - data: Box, + data: &'a RawJsonValue, event_type: &'a str, room_id: &'a RoomId, user_id: &'a UserId, diff --git a/crates/ruma-client-api/src/r0/to_device/send_event_to_device.rs b/crates/ruma-client-api/src/r0/to_device/send_event_to_device.rs index 2b2bd5cb..e10ec76b 100644 --- a/crates/ruma-client-api/src/r0/to_device/send_event_to_device.rs +++ b/crates/ruma-client-api/src/r0/to_device/send_event_to_device.rs @@ -34,7 +34,7 @@ ruma_api! { /// The content's type for this field will be updated in a future /// release, until then you can create a value using /// `serde_json::value::to_raw_value`. - pub messages: BTreeMap>> + pub messages: BTreeMap>>, } #[derive(Default)] diff --git a/crates/ruma-push-gateway-api/src/send_event_notification/v1.rs b/crates/ruma-push-gateway-api/src/send_event_notification/v1.rs index 4a7edb16..608931e9 100644 --- a/crates/ruma-push-gateway-api/src/send_event_notification/v1.rs +++ b/crates/ruma-push-gateway-api/src/send_event_notification/v1.rs @@ -112,7 +112,7 @@ pub struct Notification<'a> { /// The `content` field from the event, if present. The pusher may omit this /// if the event had no content or for any other reason. #[serde(skip_serializing_if = "Option::is_none")] - pub content: Option>, + pub content: Option<&'a RawJsonValue>, /// This is a dictionary of the current number of unacknowledged /// communications for the recipient user. Counts whose value is zero should