mirror of
https://forgejo.ellis.link/continuwuation/continuwuity.git
synced 2025-10-03 18:50:45 +00:00
Post-formatting aesthetic and spacing corrections
Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
parent
af4f66c768
commit
364293608d
72 changed files with 704 additions and 528 deletions
|
@ -1,12 +1,8 @@
|
|||
mod builder;
|
||||
mod content;
|
||||
mod count;
|
||||
mod event_id;
|
||||
mod filter;
|
||||
mod id;
|
||||
mod raw_id;
|
||||
mod redact;
|
||||
mod relation;
|
||||
#[cfg(test)]
|
||||
mod tests;
|
||||
mod unsigned;
|
||||
|
@ -24,7 +20,6 @@ pub use self::{
|
|||
Count as PduCount, Id as PduId, Pdu as PduEvent, RawId as RawPduId,
|
||||
builder::{Builder, Builder as PduBuilder},
|
||||
count::Count,
|
||||
event_id::*,
|
||||
id::{ShortId, *},
|
||||
raw_id::*,
|
||||
};
|
||||
|
@ -91,7 +86,7 @@ impl Pdu {
|
|||
|
||||
impl Event for Pdu {
|
||||
#[inline]
|
||||
fn auth_events(&self) -> impl DoubleEndedIterator<Item = &EventId> + Send + '_ {
|
||||
fn auth_events(&self) -> impl DoubleEndedIterator<Item = &EventId> + Clone + Send + '_ {
|
||||
self.auth_events.iter().map(AsRef::as_ref)
|
||||
}
|
||||
|
||||
|
@ -107,7 +102,7 @@ impl Event for Pdu {
|
|||
}
|
||||
|
||||
#[inline]
|
||||
fn prev_events(&self) -> impl DoubleEndedIterator<Item = &EventId> + Send + '_ {
|
||||
fn prev_events(&self) -> impl DoubleEndedIterator<Item = &EventId> + Clone + Send + '_ {
|
||||
self.prev_events.iter().map(AsRef::as_ref)
|
||||
}
|
||||
|
||||
|
@ -129,13 +124,22 @@ impl Event for Pdu {
|
|||
#[inline]
|
||||
fn unsigned(&self) -> Option<&RawJsonValue> { self.unsigned.as_deref() }
|
||||
|
||||
#[inline]
|
||||
fn as_mut_pdu(&mut self) -> &mut Pdu { self }
|
||||
|
||||
#[inline]
|
||||
fn as_pdu(&self) -> &Pdu { self }
|
||||
|
||||
#[inline]
|
||||
fn into_pdu(self) -> Pdu { self }
|
||||
|
||||
#[inline]
|
||||
fn is_owned(&self) -> bool { true }
|
||||
}
|
||||
|
||||
impl Event for &Pdu {
|
||||
#[inline]
|
||||
fn auth_events(&self) -> impl DoubleEndedIterator<Item = &EventId> + Send + '_ {
|
||||
fn auth_events(&self) -> impl DoubleEndedIterator<Item = &EventId> + Clone + Send + '_ {
|
||||
self.auth_events.iter().map(AsRef::as_ref)
|
||||
}
|
||||
|
||||
|
@ -151,7 +155,7 @@ impl Event for &Pdu {
|
|||
}
|
||||
|
||||
#[inline]
|
||||
fn prev_events(&self) -> impl DoubleEndedIterator<Item = &EventId> + Send + '_ {
|
||||
fn prev_events(&self) -> impl DoubleEndedIterator<Item = &EventId> + Clone + Send + '_ {
|
||||
self.prev_events.iter().map(AsRef::as_ref)
|
||||
}
|
||||
|
||||
|
@ -173,6 +177,12 @@ impl Event for &Pdu {
|
|||
#[inline]
|
||||
fn unsigned(&self) -> Option<&RawJsonValue> { self.unsigned.as_deref() }
|
||||
|
||||
#[inline]
|
||||
fn as_pdu(&self) -> &Pdu { self }
|
||||
|
||||
#[inline]
|
||||
fn into_pdu(self) -> Pdu { self.clone() }
|
||||
|
||||
#[inline]
|
||||
fn is_owned(&self) -> bool { false }
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue