Cleanup db/tag namespace
This commit is contained in:
parent
effd3f3b18
commit
80d1fa32a0
4 changed files with 71 additions and 69 deletions
src/handlers/v1
|
@ -8,7 +8,7 @@ use sqlx::{Pool, Sqlite};
|
|||
|
||||
use crate::db::errors::DatabaseError;
|
||||
use crate::db::schedules::*;
|
||||
use crate::db::tag::get_tag;
|
||||
use crate::db::tag::Tag;
|
||||
use crate::handlers::errors::ApiError;
|
||||
use crate::return_models::ReturnSchedule;
|
||||
use crate::types::EmgauwaUid;
|
||||
|
@ -44,7 +44,7 @@ pub async fn tagged(
|
|||
let mut pool_conn = pool.acquire().await?;
|
||||
|
||||
let (tag,) = path.into_inner();
|
||||
let tag_db = get_tag(&mut pool_conn, &tag).await?;
|
||||
let tag_db = Tag::get(&mut pool_conn, &tag).await?;
|
||||
|
||||
let schedules = Schedule::get_by_tag(&mut pool_conn, &tag_db).await?;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue