Uploaded image for project: 'Jira Service Management Data Center'
  1. Jira Service Management Data Center
  2. JSDSERVER-1121

Quoted message attribution not removed from comments added by email when attribution spans multiple lines

    XMLWordPrintable

Details

    Description

      The attribution line is not removed from quoted text when the length of the attribution causes it to span multiple lines.

      • The number of lines the attribution uses depends on the length of the attribution line. The length of the attribution varies based on:
        • The email address in the attribution line (always the email address of the service desk)
        • The username in the attribution line (the user who took the action that generated the notification)
        • The date and time

      The code checking for the attribution is located in servicedesk/squalor/src/main/java/com/atlassian/servicedesk/squalor/email/ServiceDeskMailUtils.java

      Example:

      Agent adds a comment using respond to customer

      • Agent username: "12345678901234" (14 characters)
      • SD Email: XXXX@XXXXXXXXXXX.XXX (20 characters)
      • Date/time of test gives attribution line: "On Wed, Nov 12, 2014 at 2:00 PM, " (32 characters)

      When agent username is shortened to 13 characters, comments added to tickets via email do not show any attribution text. When the username is 14 characters the attribution shows in comments:

      atlas added a comment - 16 minutes ago Reporter
      
      14a REPLY
      
      On Wed, Nov 12, 2014 at 1:59 PM, 12345678901234 <XXXX@XXXXXXXXXXXXXXX>
      

      Notice that "wrote:" does not appear. This part of the attribution appears on a second line and is correctly detected by "looksLikeAttribution" causing it to be removed. See below exerpt from the raw email obtained from the mailbox as a .eml file:

      --e89a8ff25500d788ab0507aede47
      Content-Type: text/plain; charset=UTF-8
      
      14a REPLY
      
      On Wed, Nov 12, 2014 at 1:59 PM, 12345678901234 <XXXX@XXXXXXXXXXXXXXX>
      wrote:
      
      >  New comment for the request "Test" with key DESK-16 has been added...
      >                         *SDTest* - Get IT help
      

      Attachments

        Issue Links

          Activity

            People

              cnguyen Chuong Nam Nguyen (Inactive)
              tevans Tim Evans (Inactive)
              Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Backbone Issue Sync