🪲 Topic Title: Duplicate Organizations with Same Name Caused by Re-login Without Invite #783
anvimotions
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
📝 Bug Description:
❗ Issue Summary
If a previously invited user is removed from an organization and later attempts to log in directly (without accepting a new invite), Postiz silently creates a new organization with the same name as the original — even if that name already exists. This leads to:
Multiple organizations with identical names (e.g., "ABC"), each with a unique id
The user becoming a Superadmin of the new org, with no channels, team members, or prior context
Confusion when trying to re-onboard or reassign roles
🔁 Steps to Reproduce
Invite user A to organization "AcmeCorp" and assign them as a member.
Remove user A from the org via admin panel.
User A visits login page and signs in using the same email (without a fresh invite).
A new organization "AcmeCorp" is auto-created.
User A is now Superadmin of this duplicate org, and cannot access original data or team.
User A should either:
Be prevented from signing in without an active invite, or
Be prompted to request access to an existing org with the same name
Or ideally, the system should not allow duplicate org names
🧪 Actual Behavior
A duplicate org is created silently
Channel approval fails due to org mismatch
Admins lose visibility unless manual DB cleanup is done
💡 Suggested Fixes
Enforce unique organization names at the DB level
Block auto org creation if org name matches an existing one
Prompt users to accept a new invite instead of self-signing up
Beta Was this translation helpful? Give feedback.
All reactions