Forced lower case tags
This commit is contained in:
parent
be769e4e3e
commit
54989f3212
2 changed files with 11 additions and 2 deletions
|
|
@ -253,7 +253,15 @@ pub async fn add_tags(
|
|||
ExtractRon(ron): ExtractRon<common::ron_api::Tags>,
|
||||
) -> Result<impl IntoResponse> {
|
||||
check_user_rights_recipe(&connection, &user, ron.recipe_id).await?;
|
||||
connection.add_recipe_tags(ron.recipe_id, &ron.tags).await?;
|
||||
connection
|
||||
.add_recipe_tags(
|
||||
ron.recipe_id,
|
||||
&ron.tags
|
||||
.into_iter()
|
||||
.map(|tag| tag.to_lowercase())
|
||||
.collect::<Vec<_>>(),
|
||||
)
|
||||
.await?;
|
||||
Ok(StatusCode::OK)
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue