Uploaded image for project: 'Jira Cloud'
  1. Jira Cloud
  2. JRACLOUD-62777

In the JIRA to JIRA Copy Plugin, users where usernames != key aren't getting mapped correctly

    XMLWordPrintable

Details

    Description

      NOTE: This bug report is for JIRA Cloud. Using JIRA Server? See the corresponding bug report.

      UserMappingManager#createUserBean is not passed a username like the signature and implementation seem to expect, but a key. This causes the "user" variable to be null for some users when they don't have matching usernames/keys in the following piece of code:

          public UserBean createUserBean(final String userName)
          {
              Assertions.notBlank("userName", userName);
              ApplicationUser user = userManager.getUserObject(userName);
              if (user == null)
              {
                  return null;
              }
              else
              {
                  return new UserBean(user.getName(), user.getEmailAddress(), user.getDisplayName());
              }
          }
      

       
      UserManager#getUserObject expects a username as argument.

      End result is that, for example, comments belonging to such users don't get copied over.

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              4e05f15201f2 SanderK
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: