diff --git a/src/main.rs b/src/main.rs index f615063..1bff798 100644 --- a/src/main.rs +++ b/src/main.rs @@ -144,7 +144,7 @@ async fn current(db: web::Data) -> impl Responder { HttpResponse::Ok().json(result) } -#[get("/imlonghao-api/logs")] +#[get("/api/logs")] async fn logs(db: web::Data) -> impl Responder { let conn = db.get().await.unwrap(); let rows = conn @@ -182,7 +182,7 @@ async fn logs(db: web::Data) -> impl Responder { HttpResponse::Ok().json(results) } -#[get("/imlonghao-api/pkg/{name}")] +#[get("/api/pkg/{name}")] async fn get_pkg( name: web::Path, db: web::Data, @@ -220,7 +220,7 @@ async fn get_pkg( HttpResponse::Ok().json(results) } -#[get("/imlonghao-api/pkg/{name}/log/{ts}")] +#[get("/api/pkg/{name}/log/{ts}")] async fn get_pkg_log( path: web::Path<(String, i64)>, db: web::Data,