changed api apth
This commit is contained in:
parent
14029ef399
commit
cbb8fe9555
|
@ -20,7 +20,6 @@ pub(crate) async fn start_actix(config: &Config, database: Database) -> anyhow::
|
|||
.service(actix_fs::Files::new("/static", "./static").index_file("index.html")) // static directory
|
||||
.service(web::redirect("/favicon.ico", "/static/favicon.ico")) //? special redirect for favicon
|
||||
})
|
||||
|
||||
.bind(bindip)?
|
||||
.run()
|
||||
.await?;
|
||||
|
|
|
@ -3,15 +3,13 @@ pub mod events;
|
|||
|
||||
use std::{borrow::BorrowMut, sync::Mutex};
|
||||
|
||||
use actix_web::{http::header, web::{self, Bytes, Data}, HttpRequest, HttpResponse, Responder, Result, Scope};
|
||||
use actix_web::{http::header, web::{self, Bytes, Data}, HttpRequest, HttpResponse, Resource, Responder, Result, Scope};
|
||||
|
||||
use crate::database::{models, Database};
|
||||
|
||||
pub fn get_scope() -> Scope {
|
||||
Scope::new("/github")
|
||||
.service(
|
||||
web::resource("/")
|
||||
.to(handler)
|
||||
pub fn get_scope() -> Resource {
|
||||
web::resource("/").route(
|
||||
web::route().to(handler)
|
||||
)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user