From 396fad5bc1721a826171aa27af404760984ea5cd Mon Sep 17 00:00:00 2001 From: wangj Date: Tue, 28 Sep 2021 10:20:22 +0800 Subject: [PATCH 1/3] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20'README.md'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 1cb142db6..afb2da5d9 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@

logoAiForge - 启智AI开发协作平台

-[![release](https://img.shields.io/badge/release-1.21.9.2-blue)](https://git.openi.org.cn/OpenI/aiforge/releases/latest) +[![release](https://img.shields.io/badge/release-1.21.10.1-blue)](https://git.openi.org.cn/OpenI/aiforge/releases/latest) [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT) From 4993f06d63bd9c02a212ea628776ea642cdbe742 Mon Sep 17 00:00:00 2001 From: avadesian Date: Tue, 28 Sep 2021 15:30:02 +0800 Subject: [PATCH 2/3] =?UTF-8?q?=E8=B4=A1=E7=8C=AE=E8=80=85=E5=88=97?= =?UTF-8?q?=E8=A1=A8=E5=85=B3=E8=81=94=E9=9A=90=E8=97=8F=E9=82=AE=E4=BB=B6?= =?UTF-8?q?=E5=9C=B0=E5=9D=80=E7=9A=84=E7=94=A8=E6=88=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- models/user.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/models/user.go b/models/user.go index 38f699740..78ab4627a 100755 --- a/models/user.go +++ b/models/user.go @@ -1556,6 +1556,18 @@ func GetUserByActivateEmail(email string) (*User, error) { if len(users) >= 1 { return &users[0],nil }else { + // Finally, if email address is the protected email address:用户邮件地址设置为隐藏电子邮件地址 + if strings.HasSuffix(email, fmt.Sprintf("@%s", setting.Service.NoReplyAddress)) { + username := strings.TrimSuffix(email, fmt.Sprintf("@%s", setting.Service.NoReplyAddress)) + user := &User{LowerName: username} + has, err := ctx.e.Get(user) + if err != nil { + return nil, err + } + if has { + return user, nil + } + } return nil, errors.New("cannot find user by email") } } From fe24ad930572d7a4851bfce6a2f023f2eba3691a Mon Sep 17 00:00:00 2001 From: avadesian Date: Tue, 28 Sep 2021 16:26:19 +0800 Subject: [PATCH 3/3] patch for release V1.21.9.2 --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index afb2da5d9..1cb142db6 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@

logoAiForge - 启智AI开发协作平台

-[![release](https://img.shields.io/badge/release-1.21.10.1-blue)](https://git.openi.org.cn/OpenI/aiforge/releases/latest) +[![release](https://img.shields.io/badge/release-1.21.9.2-blue)](https://git.openi.org.cn/OpenI/aiforge/releases/latest) [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT)