feat: implement remote unfollow — wire FederationActionPort through delete_follow handler

This commit is contained in:
2026-05-15 02:46:24 +02:00
parent eebdbeaaf2
commit 031a22514d
5 changed files with 100 additions and 7 deletions

View File

@@ -223,6 +223,11 @@ pub trait RemoteActorConnectionRepository: Send + Sync {
pub trait FederationActionPort: Send + Sync {
async fn lookup_actor(&self, handle: &str) -> Result<RemoteActor, DomainError>;
async fn follow_remote(&self, local_user_id: &UserId, handle: &str) -> Result<(), DomainError>;
async fn unfollow_remote(
&self,
local_user_id: &UserId,
handle: &str,
) -> Result<(), DomainError>;
async fn actor_json(&self, user_id: &UserId) -> Result<String, DomainError>;
async fn followers_collection_json(
&self,

View File

@@ -548,6 +548,14 @@ impl FederationActionPort for TestStore {
Ok(())
}
async fn unfollow_remote(
&self,
_local_user_id: &UserId,
_handle: &str,
) -> Result<(), DomainError> {
Ok(())
}
async fn actor_json(&self, _user_id: &UserId) -> Result<String, DomainError> {
Err(DomainError::NotFound)
}