FIX invite redeem more robust

This commit is contained in:
Sam 2014-07-17 09:38:16 +10:00
parent 189b1c729a
commit d56d7866ff
1 changed files with 1 additions and 1 deletions

View File

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