Closed Bug 463777 Opened 16 years ago Closed 16 years ago

Gloda autocomplete error when no "popular" contacts/identities exist [this.identityCollection is undefined]

Categories

(MailNews Core :: Backend, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
Thunderbird 3.0b1

People

(Reporter: asuth, Assigned: asuth)

References

Details

Attachments

(1 file, 1 obsolete file)

When gloda is started with a clean database and has not made any contacts be popular, the query for popular contacts will return with 0 contacts.  Accordingly, there will be no identity sub-collection associated, which means that glautocomp's cleverness in attempting to fish out the identity collection will fail.  I had already dealt with this partially, but was in a rush and didn't get it all.

This fix is the one I discussed with davida.  In a nutshell, it's okay to pass undefined to concat, and we use && in order to short-circuit return undefined rather than attempting to dereference it.
Attachment #347039 - Flags: review?(dmose)
Comment on attachment 347039 [details] [diff] [review]
v1 evaluate to undefined rather than dereferencing

r=dmose, conditional on adding a comment explaining what's going on
Attachment #347039 - Flags: review?(dmose) → review+
Blocks: 464354
added requested comment, carrying forward r=dmose.
Assignee: nobody → bugmail
Attachment #347039 - Attachment is obsolete: true
Status: NEW → ASSIGNED
Attachment #348852 - Flags: review+
Keywords: checkin-needed
blocking b1
Flags: blocking-thunderbird3.0b1+
Target Milestone: --- → Thunderbird 3.0b1
Checked in: http://hg.mozilla.org/comm-central/rev/e5d97c6bdbce
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: