fix: 自定义翻译简体中文统一使用 zh-hans
This commit is contained in:
@@ -85,7 +85,7 @@ def translate_text(user):
|
||||
text = (data.get("text") or "").strip()
|
||||
if not text:
|
||||
return jsonify({"error": "翻译内容不能为空"}), 400
|
||||
source = (data.get("source") or "zh").strip()
|
||||
source = (data.get("source") or "zh-hans").strip()
|
||||
target = (data.get("target") or "es").strip()
|
||||
settings = get_user_settings(user["id"])
|
||||
result = perform_translate(text, settings, source, target)
|
||||
|
||||
Reference in New Issue
Block a user