potree-auth 0.1.0

Authentication and project management for `potree` point clouds.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use axum::response::IntoResponse;
use axum::response::Response;

use crate::common::domain::StaticAsset;

/// Enables a [`StaticAsset`] to be easily converted into an `axum` HTTP
/// response.
impl IntoResponse for StaticAsset {
    fn into_response(self) -> Response {
        let response = self.0;
        let (parts, body) = response.into_parts();
        Response::from_parts(parts, axum::body::Body::from(body))
    }
}