Skip to content

fix: while creating a new account, check for his existance#13187

Open
madbob wants to merge 1 commit into
nextcloud:mainfrom
madbob:issue_12042
Open

fix: while creating a new account, check for his existance#13187
madbob wants to merge 1 commit into
nextcloud:mainfrom
madbob:issue_12042

Conversation

@madbob

@madbob madbob commented Jun 30, 2026

Copy link
Copy Markdown
Collaborator

Unsure if the duplication check should span across all existing accounts on the instance, or just those registered by the current user...

Fixes #12042

@ChristophWurst ChristophWurst self-assigned this Jul 1, 2026
@ChristophWurst ChristophWurst added bug 3. to review comp:setup All tickets regarding the setup component labels Jul 1, 2026
@ChristophWurst

Copy link
Copy Markdown
Member

Thanks for the PR

@GretaD GretaD left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it works, thank you

Image

@GretaD

GretaD commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

/backport to stable5.10

@GretaD

GretaD commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

would it be possible for you to write a quick test about this check?

Signed-off-by: Roberto Guido <info@madbob.org>
@ChristophWurst

Copy link
Copy Markdown
Member

What I'm missing

  1. Same logic for occ mail:account:create or moved check
  2. Strategy for existing accounts
  3. (Eventually) a UNIQUE INDEX in the db because that is the only way to assure the constraint

@madbob

madbob commented Jul 14, 2026

Copy link
Copy Markdown
Collaborator Author
  1. Same logic for occ mail:account:create or moved check

I'm going to check.

  1. Strategy for existing accounts

In my opinion, this cannot be retroactive. What is done, is done.

  1. (Eventually) a UNIQUE INDEX in the db because that is the only way to assure the constraint

This implementation just checks that the current user do not register multiple times the same mail account, but no one specified what happens if different users register the same mail account. If allowed: it cannot be unique in the database. If not allowed: this implementation is wrong.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review backport-request bug comp:setup All tickets regarding the setup component

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Don't allow duplicate account setup

4 participants