From 93c27b134da5cbd363be7c2aa1b6aab5b9edcaf9 Mon Sep 17 00:00:00 2001 From: NeatGuyCoding <15627489+NeatGuyCoding@users.noreply.github.com> Date: Thu, 17 Jul 2025 13:52:15 +0800 Subject: [PATCH] minor typo fix: remove debug code and fix typo (#22539) --- api/controllers/console/auth/error.py | 6 +++--- api/controllers/console/workspace/members.py | 2 -- api/templates/change_mail_confirm_old_template_zh-CN.html | 1 - .../transfer_workspace_owner_confirm_template_en-US.html | 2 +- .../change_mail_confirm_old_template_zh-CN.html | 1 - .../transfer_workspace_owner_confirm_template_en-US.html | 2 +- 6 files changed, 5 insertions(+), 9 deletions(-) diff --git a/api/controllers/console/auth/error.py b/api/controllers/console/auth/error.py index f4a8b9748..8c5e23de5 100644 --- a/api/controllers/console/auth/error.py +++ b/api/controllers/console/auth/error.py @@ -27,19 +27,19 @@ class InvalidTokenError(BaseHTTPException): class PasswordResetRateLimitExceededError(BaseHTTPException): error_code = "password_reset_rate_limit_exceeded" - description = "Too many password reset emails have been sent. Please try again in 1 minutes." + description = "Too many password reset emails have been sent. Please try again in 1 minute." code = 429 class EmailChangeRateLimitExceededError(BaseHTTPException): error_code = "email_change_rate_limit_exceeded" - description = "Too many email change emails have been sent. Please try again in 1 minutes." + description = "Too many email change emails have been sent. Please try again in 1 minute." code = 429 class OwnerTransferRateLimitExceededError(BaseHTTPException): error_code = "owner_transfer_rate_limit_exceeded" - description = "Too many owner tansfer emails have been sent. Please try again in 1 minutes." + description = "Too many owner transfer emails have been sent. Please try again in 1 minute." code = 429 diff --git a/api/controllers/console/workspace/members.py b/api/controllers/console/workspace/members.py index 30a4148db..b1f79ffde 100644 --- a/api/controllers/console/workspace/members.py +++ b/api/controllers/console/workspace/members.py @@ -264,11 +264,9 @@ class OwnerTransfer(Resource): transfer_token_data = AccountService.get_owner_transfer_data(args["token"]) if not transfer_token_data: - print(transfer_token_data, "transfer_token_data") raise InvalidTokenError() if transfer_token_data.get("email") != current_user.email: - print(transfer_token_data.get("email"), current_user.email) raise InvalidEmailError() AccountService.revoke_owner_transfer_token(args["token"]) diff --git a/api/templates/change_mail_confirm_old_template_zh-CN.html b/api/templates/change_mail_confirm_old_template_zh-CN.html index 4a3e35cfb..23c9e4665 100644 --- a/api/templates/change_mail_confirm_old_template_zh-CN.html +++ b/api/templates/change_mail_confirm_old_template_zh-CN.html @@ -111,7 +111,6 @@
验证您的邮箱变更请求
我们收到了一个变更您 Dify 账户关联邮箱地址的请求。
-我们收到了一个变更您 Dify 账户关联邮箱地址的请求。
此验证码仅在接下来的5分钟内有效:
If you didn’t make this request, please ignore this email or contact support immediately.
验证您的邮箱变更请求
我们收到了一个变更您 Dify 账户关联邮箱地址的请求。
-我们收到了一个变更您 Dify 账户关联邮箱地址的请求。
此验证码仅在接下来的5分钟内有效:
If you didn’t make this request, please ignore this email or contact support immediately.