Signing activities

I hope it works correctly…

Fixes #6
This commit is contained in:
Bat
2018-05-03 20:11:04 +01:00
parent 6b372861d6
commit 22cb286f86
11 changed files with 98 additions and 27 deletions
+1 -1
View File
@@ -56,7 +56,7 @@ fn create(blog_name: String, data: Form<NewPostForm>, user: User, conn: DbConn)
});
let act = Create::new(&user, &post, &*conn);
broadcast(&*conn, act, user.get_followers(&*conn));
broadcast(&*conn, &user, act, user.get_followers(&*conn));
Redirect::to(format!("/~/{}/{}", blog_name, slug).as_str())
}
+1 -1
View File
@@ -34,7 +34,7 @@ fn follow(name: String, conn: DbConn, user: User) -> Redirect {
follower_id: user.id,
following_id: target.id
});
target.send_to_inbox(&*conn, activity::Follow::new(&user, &target, &*conn));
target.send_to_inbox(&*conn, &user, activity::Follow::new(&user, &target, &*conn));
Redirect::to(format!("/@/{}", name).as_ref())
}