FIX: only allow one user to be created per invite

This commit is contained in:
Arpit Jalan
2018-04-27 19:21:10 +05:30
parent 458b9c3a62
commit 67357b84b9
2 changed files with 14 additions and 1 deletions

View File

@@ -11,7 +11,7 @@ InviteRedeemer = Struct.new(:invite, :username, :name, :password, :user_custom_f
# If `invite_passthrough_hours` is defined, allow them to re-use the invite link
# to login again.
if invite.redeemed_at && invite.redeemed_at >= SiteSetting.invite_passthrough_hours.hours.ago
return invited_user
return get_existing_user
end
nil