]> Untitled Git - lemmy.git/commit
Remove SendActivity and Perform traits, rely on channel (#3596)
authorNutomic <me@nutomic.com>
Wed, 19 Jul 2023 13:49:41 +0000 (15:49 +0200)
committerGitHub <noreply@github.com>
Wed, 19 Jul 2023 13:49:41 +0000 (09:49 -0400)
commit5d23ef960e3361d1cc38c1aff1d907d8da58b90f
tree3819098ccc8acb9476462bf620b50729ab0b3158
parent77a8e3b8979c4c65edb7ba6c7df4907518dc05c5
Remove SendActivity and Perform traits, rely on channel (#3596)

* Remove SendActivity and Perform traits, rely on channel

These traits arent necessary anymore now that websocket is removed.
Removing them allows us to use normal actix http handler methods
which are much more flexible, and allow using different middlewares
as well as setting response attributes.

* compiling and create post federating

* clippy

* rename methods, join outgoing activities task

* fix api tests

* no unwrap

* conditional compile

* add back getrandom

* make crates optional

* fmt
12 files changed:
Cargo.lock
crates/api_common/Cargo.toml
crates/api_common/src/build_response.rs
crates/api_common/src/lib.rs
crates/api_common/src/send_activity.rs [new file with mode: 0644]
crates/api_crud/src/lib.rs
crates/api_crud/src/post/create.rs
crates/api_crud/src/post/mod.rs
crates/apub/src/activities/create_or_update/post.rs
crates/apub/src/activities/mod.rs
src/api_routes_http.rs
src/lib.rs