Last Comment Bug 855057 - handle account name that is a substring of another one properly in the activity manager
: handle account name that is a substring of another one properly in the activi...
Status: RESOLVED FIXED
:
Product: Thunderbird
Classification: Client Software
Component: Mail Window Front End (show other bugs)
: Trunk
: All All
: -- minor (vote)
: Thunderbird 23.0
Assigned To: :aceman
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-03-26 14:09 PDT by :aceman
Modified: 2013-04-13 05:12 PDT (History)
1 user (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---


Attachments
patch (2.63 KB, patch)
2013-03-26 15:07 PDT, :aceman
mconley: review+
Details | Diff | Review

Description :aceman 2013-03-26 14:09:01 PDT
In mail/components/activity/modules/autosync.js there is this code:

    for (let i = 1; i < this._inQFolderList.length; i++) {
      // do not include already existing account names
      if (!accountList.contains(this._inQFolderList[i].server.prettyName))
        accountList = accountList + ", " + this._inQFolderList[i].server.prettyName;
    }

This is not a proper way to exclude duplicate names as account names can be substrings of each other.
Comment 1 :aceman 2013-03-26 15:07:37 PDT
Created attachment 729819 [details] [diff] [review]
patch
Comment 2 Mike Conley (:mconley) - (Needinfo me!) 2013-04-08 22:53:14 PDT
Comment on attachment 729819 [details] [diff] [review]
patch

Review of attachment 729819 [details] [diff] [review]:
-----------------------------------------------------------------

Yes, this is much better. Thanks aceman!
Comment 3 Ryan VanderMeulen [:RyanVM] 2013-04-13 05:12:39 PDT
https://hg.mozilla.org/comm-central/rev/aaca24426463

Note You need to log in before you can comment on or make changes to this bug.