Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-9903

Adding multiple time the same scm account to a user should ignore duplicates

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 6.7
    • Component/s: Scm, Web API
    • Labels:

      Description

      In api/users/update it's currently possible to update the scm account of the user with the same account value multiple time. Multiple occurrence of the same value is not correctly handled and saved multiple time, preventing later from deleting that scm account.

      Example of body that should ignore the second occurrence of the scm :

      login:admin
      name:Admin Admin
      email:infra@sonarsource.com
      scmAccount:foo
      scmAccount:foo
      

      I also noticed that deleting all scm account for a user doesn't work, there is always at least one remaining that it's not possible to remove.

      Changes:

      • ignore duplicate SCM accounts
      • order by alphabetical order, case insensitive
      • delete all scm accounts should work

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                teryk.bellahsene Teryk Bellahsene (Inactive)
                Reporter:
                gregoire.aubert Gregoire Aubert
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Due:
                  Created:
                  Updated:
                  Resolved: