liquid-rescale-api/src/routes/liquid.rs

11 lines
341 B
Rust
Raw Normal View History

2023-04-03 01:29:27 +00:00
use axum::{extract::Multipart, Json};
use crate::{
processors::liquid_rescale_processor::liquid_rescale_processor, utilities::app_error::AppError,
};
pub async fn liquid_rescale_route(multipart: Multipart) -> Result<Json<Vec<u8>>, AppError> {
let image_data = liquid_rescale_processor(multipart).await?;
Ok(Json(image_data))
}