remove whitespace from TTS model titles

This commit is contained in:
Brandon Thomas committed 2023-01-20 03:27:39 -05:00
1 parent d46778569c
commit 993fe647b4
2 files changed
+2 -2

No files matched your search

@@ -203,7 +203,7 @@ pub async fn edit_tts_model_handler(
return Err(EditTtsModelError::BadInput("title contains slurs".to_string()));
}
title = Some(payload.to_string());
title = Some(payload.trim().to_string());
}
if let Some(markdown) = request.description_markdown.as_deref() {
@@ -120,7 +120,7 @@ pub async fn upload_tts_model_handler(
let ip_address = get_request_ip(&http_request);
let uuid = request.idempotency_token.to_string();
let title = request.title.to_string();
let title = request.title.trim().to_string();
let download_url = request.download_url.to_string();
match is_bad_tts_model_download_url(&download_url) {