Invite links show error for Admin users

Hi

Invitation links that are working for standard users show an error for logged in admin users. The following is a screenshot of the error:
670x180
And this is a screenshot of the Network response:


The invitation links are created by system, adds users to groups and redirects them to topic post. Working well for standard users and have been so for a while now. However, this error started appearing only for admin users.

Please help! I’m posting this with hopes that this will be fixed and it won’t be something we’ll need to fix for standard users as well.

Thank you!

2 Likes

Hi @gassim :slight_smile:

Is there more detail in /logs you could share?

I searched Meta for that error message and there’s a mention about minimum username length from some time back in a similar situation: Setting 'min username length' greater than 5 breaks granting and revoking Admin/Moderator permissions - #10 by RGJ Could that be relevant?

2 Likes

Hi @JammyDodger,

Thanks! However, it doesn’t seem relevant nor is it a similar situation.

We’re not making any change here. The invite links used to work but now when an admin clicks on an invite link the error above appears which never appeared before.

2 Likes

That was a bit of a longshot. :slightly_smiling_face: I thought possibly the admin invite links were causing a similar conflict, but if you haven’t updated that setting then perhaps not.

Hopefully your /logs can provide more detailed info for the error?

2 Likes

Thanks @JammyDodger! Sorry for taking long.

Here’s the /log error (which is not supposed to happen):
ActiveRecord::RecordInvalid (Validation failed: Primary email has already been taken) app/models/invite_redeemer.rb:72:in `create_user_from_invite' app/models/invite_redeemer.rb:144:in `get_invited_us


Failed to handle exception in exception app middleware : ActiveRecord::RecordInvalid : Validation failed: Primary email has already been taken


It’s not supposed to do that! What it used to do before is that if I’m logged in and used an invite link, it would simply add me to the group (if I’m not already a member in) and it’d redirect me to the topic post.

rather than display the error:

1 Like