mirror of
https://github.com/lennart-k/rustical.git
synced 2025-12-14 23:02:31 +00:00
edit resource.rs
This commit is contained in:
@@ -171,14 +171,15 @@ pub trait ResourceService: Sized + 'static {
|
|||||||
|
|
||||||
#[inline]
|
#[inline]
|
||||||
fn actix_resource() -> actix_web::Resource {
|
fn actix_resource() -> actix_web::Resource {
|
||||||
let propfind_method = || web::method(Method::from_str("PROPFIND").unwrap());
|
|
||||||
let proppatch_method = || web::method(Method::from_str("PROPPATCH").unwrap());
|
|
||||||
|
|
||||||
Self::actix_additional_routes(
|
Self::actix_additional_routes(
|
||||||
web::resource("")
|
web::resource("")
|
||||||
.name(Self::resource_name())
|
.name(Self::resource_name())
|
||||||
.route(propfind_method().to(route_propfind::<Self>))
|
.route(
|
||||||
.route(proppatch_method().to(route_proppatch::<Self>))
|
web::method(Method::from_str("PROPFIND").unwrap()).to(route_propfind::<Self>),
|
||||||
|
)
|
||||||
|
.route(
|
||||||
|
web::method(Method::from_str("PROPPATCH").unwrap()).to(route_proppatch::<Self>),
|
||||||
|
)
|
||||||
.delete(route_delete::<Self>),
|
.delete(route_delete::<Self>),
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user