This commit is contained in:
asonix
2020-04-25 20:49:29 -05:00
parent a417a3d054
commit 0b2763ab8b
13 changed files with 27 additions and 28 deletions
+1 -1
View File
@@ -12,7 +12,7 @@ pub struct Reject(pub Actor);
impl Reject {
async fn perform(self, state: JobState) -> Result<(), anyhow::Error> {
if let Some(_) = state.actors.unfollower(&self.0).await? {
if state.actors.unfollower(&self.0).await?.is_some() {
state.db.remove_listener(self.0.inbox.clone()).await?;
}
+1 -1
View File
@@ -22,7 +22,7 @@ impl Undo {
async fn perform(self, state: JobState) -> Result<(), anyhow::Error> {
let was_following = state.actors.is_following(&self.actor.id).await;
if let Some(_) = state.actors.unfollower(&self.actor).await? {
if state.actors.unfollower(&self.actor).await?.is_some() {
state.db.remove_listener(self.actor.inbox.clone()).await?;
}