Edit create migrations

This commit is contained in:
2023-09-07 21:30:46 -04:00
parent 17d7407f1b
commit 8c2a6368ad
10 changed files with 51 additions and 95 deletions

View File

@@ -2,17 +2,6 @@ use crate::error_handler::CustomError;
use crate::metars::Metars;
use actix_web::{get, web, HttpResponse, Responder};
// #[get("metars/{ids}")]
// async fn get_all(ids: web::Path<String>) -> Result<HttpResponse, CustomError> {
// let airports = web::block(|| Ok::<_, CustomError>(async {Metars::get_all(ids.into_inner()).await}))
// .await
// .unwrap()
// .unwrap()
// .await
// .unwrap();
// Ok(HttpResponse::Ok().json(airports))
// }
#[get("metars/{ids}")]
async fn get_all(ids: web::Path<String>) -> impl Responder {
let airports = web::block(|| Ok::<_, CustomError>(async {Metars::get_all(ids.into_inner()).await}))