Big repository reorganization
The code is divided in three crates: - plume-common, for the ActivityPub module, and some common utils - plume-models, for the models and database-related code - plume, the app itself This new organization will allow to test it more easily, but also to create other tools that only reuse a little part of the code (for instance a Wordpress import tool, that would just use the plume-models crate)
This commit is contained in:
+4
-5
@@ -1,16 +1,15 @@
|
||||
use rocket::response::{Redirect, Flash};
|
||||
|
||||
use activity_pub::{broadcast, inbox::Notify};
|
||||
use db_conn::DbConn;
|
||||
use models::{
|
||||
use plume_common::activity_pub::{broadcast, inbox::Notify};
|
||||
use plume_common::utils;
|
||||
use plume_models::{
|
||||
blogs::Blog,
|
||||
db_conn::DbConn,
|
||||
likes,
|
||||
posts::Post,
|
||||
users::User
|
||||
};
|
||||
|
||||
use utils;
|
||||
|
||||
#[get("/~/<blog>/<slug>/like")]
|
||||
fn create(blog: String, slug: String, user: User, conn: DbConn) -> Redirect {
|
||||
let b = Blog::find_by_fqn(&*conn, blog.clone()).unwrap();
|
||||
|
||||
Reference in New Issue
Block a user