# 所有新创建和先前创建的邀请链接在邀请系统最近更改后都将被作废

**URL:** https://meta.discourse.org/t/all-newly-and-previously-created-invitation-links-are-being-invalidated-after-recent-changes-to-the-invitation-system/246624
**Category:** Bug
**Tags:** invites
**Created:** [2022 年11 月 24 日 09:09 UTC](https://meta.discourse.org/t/all-newly-and-previously-created-invitation-links-are-being-invalidated-after-recent-changes-to-the-invitation-system/246624 "2022-11-24T09:09:34Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### 作者： ![gassim](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gassim/32/220910_2.png) [@gassim](https://meta.discourse.org/u/gassim)
#### 发布日期： [2022 年11 月 24 日 09:09 UTC](https://meta.discourse.org/t/all-newly-and-previously-created-invitation-links-are-being-invalidated-after-recent-changes-to-the-invitation-system/246624/1 "2022-11-24T09:09:34Z")

</div>

您好

由于最近对邀请系统核心功能进行的更改，我们的一组邀请链接已失效。尽管尚未达到到期日期或兑换次数限制，但它们已不再按预期工作。

首先，使用旨在重定向到某个主题的邀请链接注册后，新用户在激活帐户后不会被重定向。以前，激活后会发生两件事：一个“通知”通知以及将新用户重定向到主题帖子。此外，将用户添加到组的功能也不再有效。注册后，该人员不再被添加到组中。（此相同错误之前已在此处修复：**[here](https://meta.discourse.org/t/invite-links-to-topic-send-user-to-home-page-not-to-topic/221078)**）

其次，使用链接注册后，如果再次单击相同的邀请链接，将显示消息：“ **您已兑换过此邀请链接。** ”好的，根据[最近的更改](https://meta.discourse.org/t/new-accept-invitation-prompt-feature-causing-issues-with-invitation-links/245115)，我们理解用户不能重复使用邀请链接；但是，所有先前创建的和新的邀请链接对 **现有成员** 不再有效。问题是，在未登录用户的浏览器中用于注册新帐户时“有效”的相同邀请链接，对现有成员无效，他们将收到错误消息：“ **此邀请无法兑换。请要求邀请您的人向您发送新邀请。** ”

这两个问题都发生在所有新创建和先前创建的邀请链接上，没有任何理由或警告表明它们对现有成员无效（或停止将新用户重定向到主题并将他们添加到组中）。是的，新成员可以加入，但这也不完整，因为他们没有被重定向或添加到组中。我认为这是由于新更改而导致的错误。

希望我们能尽快解决这个问题！坦率地说，我理解可能已采取敏捷方法来强制执行邀请链接的“安全性”，但我希望在强制执行之前，所有这些内容都经过彻底测试。我们依赖这些邀请链接来管理课程参与者，正如我的一位同事所说，“这对我们当前的课程产生了影响，这很麻烦”！！

谢谢！

---

<div class="post-metadata">

### 作者： ![jessicafjc](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/jessicafjc/32/278704_2.png) [@jessicafjc](https://meta.discourse.org/u/jessicafjc)
#### 发布日期： [2022 年11 月 25 日 02:59 UTC](https://meta.discourse.org/t/all-newly-and-previously-created-invitation-links-are-being-invalidated-after-recent-changes-to-the-invitation-system/246624/2 "2022-11-25T02:59:57Z")

</div>

我遇到了同样的问题，正在等待修复。

---

<div class="post-metadata">

### 作者： ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### 发布日期： [2022 年11 月 25 日 03:27 UTC](https://meta.discourse.org/t/all-newly-and-previously-created-invitation-links-are-being-invalidated-after-recent-changes-to-the-invitation-system/246624/3 "2022-11-25T03:27:23Z")

</div>

> [@gassim](#):
>
> 所有先前创建和新的邀请链接对 **现有成员** 不再有效。

我们刚刚修复了这个问题：

> <https://github.com/discourse/discourse/commit/bbcb69461fd85af0e1d883cfbc8240c200e748e9>
>
> Follow up to 40e8912395ee2dc0f43c2b2a4504f4984c1f040d
> 
> In this previous commit… I introduced a bug that prevented
> a legitimate case for an existing user to redeem an invite,
> where the email/domain were both blank and the invite was
> still redeemable by the user. Fixes the issue and adds more
> specs for that case.

我应该继续关闭这个主题吗？

---

<div class="post-metadata">

### 作者： ![gassim](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/gassim/32/220910_2.png) [@gassim](https://meta.discourse.org/u/gassim)
#### 发布日期： [2022 年11 月 25 日 09:01 UTC](https://meta.discourse.org/t/all-newly-and-previously-created-invitation-links-are-being-invalidated-after-recent-changes-to-the-invitation-system/246624/4 "2022-11-25T09:01:43Z")

</div>

你好 @sam

谢谢你的修复，也谢谢你的提问！

如果以下问题已解决（现有成员首次使用邀请链接将用户重定向到相关主题并将其添加到特定组 + 新用户注册后也是如此），那么没问题，请关闭此主题！

> [@gassim](#):
>
> 新成员激活账户后未被重定向。

> [@gassim](#):
>
> 此外，将用户添加到组的功能不再有效。

> [@gassim](#):
>
> 他们既没有被重定向，也没有被添加到组中。

谢谢！ 🙂

---

<div class="post-metadata">

### 作者： ![sam](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/sam/32/102149_2.png) [@sam](https://meta.discourse.org/u/sam)
#### 发布日期： [2022 年11 月 25 日 10:20 UTC](https://meta.discourse.org/t/all-newly-and-previously-created-invitation-links-are-being-invalidated-after-recent-changes-to-the-invitation-system/246624/5 "2022-11-25T10:20:33Z")

</div>


