Files
AstralRinth/apps/labrinth/src/routes/not_found.rs
2024-10-16 14:11:42 -07:00

12 lines
299 B
Rust

use crate::models::error::ApiError;
use actix_web::{HttpResponse, Responder};
pub async fn not_found() -> impl Responder {
let data = ApiError {
error: "not_found",
description: "the requested route does not exist".to_string(),
};
HttpResponse::NotFound().json(data)
}