Fix clippy warnings
This commit is contained in:
parent
0e49b70d65
commit
401c0b07b3
@ -40,6 +40,7 @@ impl Serialize for Relation {
|
||||
where
|
||||
S: Serializer,
|
||||
{
|
||||
#[allow(clippy::needless_update)]
|
||||
let relates_to = match self {
|
||||
#[cfg(feature = "unstable-pre-spec")]
|
||||
Relation::Annotation(r) => RelatesToJsonRepr {
|
||||
|
@ -43,6 +43,7 @@ impl Serialize for Relation {
|
||||
where
|
||||
S: Serializer,
|
||||
{
|
||||
#[allow(clippy::needless_update)]
|
||||
let json_repr = match self {
|
||||
Relation::Reply { in_reply_to } => EventWithRelatesToJsonRepr::new(RelatesToJsonRepr {
|
||||
in_reply_to: Some(in_reply_to.clone()),
|
||||
|
@ -55,7 +55,7 @@ fn serialize_pdu_as_v1() {
|
||||
"event_id": "$somejoinevent:matrix.org",
|
||||
"sender": "@sender:example.com",
|
||||
"origin": "matrix.org",
|
||||
"origin_server_ts": 1_592_050_773_658u64,
|
||||
"origin_server_ts": 1_592_050_773_658_u64,
|
||||
"type": "m.room.power_levels",
|
||||
"content": {
|
||||
"testing": 123
|
||||
@ -114,7 +114,7 @@ fn serialize_pdu_as_v3() {
|
||||
"room_id": "!n8f893n9:example.com",
|
||||
"sender": "@sender:example.com",
|
||||
"origin": "matrix.org",
|
||||
"origin_server_ts": 1_592_050_773_658u64,
|
||||
"origin_server_ts": 1_592_050_773_658_u64,
|
||||
"type": "m.room.power_levels",
|
||||
"content": {
|
||||
"testing": 123
|
||||
|
Loading…
x
Reference in New Issue
Block a user