style: clippy fixes and linter formatting

This commit is contained in:
2026-05-29 01:52:14 +02:00
parent df6ff4c1e8
commit 73a68860c1
27 changed files with 1090 additions and 440 deletions

View File

@@ -1,8 +1,5 @@
use activitypub_federation::{
config::Data,
fetch::object_id::ObjectId,
kinds::activity::CreateType,
traits::Activity,
config::Data, fetch::object_id::ObjectId, kinds::activity::CreateType, traits::Activity,
};
use serde::{Deserialize, Serialize};
use url::Url;
@@ -36,8 +33,12 @@ impl Activity for CreateActivity {
type DataType = FederationData;
type Error = Error;
fn id(&self) -> &Url { &self.id }
fn actor(&self) -> &Url { self.actor.inner() }
fn id(&self) -> &Url {
&self.id
}
fn actor(&self) -> &Url {
self.actor.inner()
}
async fn verify(&self, _data: &Data<Self::DataType>) -> Result<(), Self::Error> {
if let Some(attributed_to) = self.object.get("attributedTo").and_then(|v| v.as_str())