Closed
Bug 818158
Opened 12 years ago
Closed 12 years ago
mozContact.find() - contains lookup on the "tel" field failing
Categories
(Core :: DOM: Device Interfaces, defect, P2)
Tracking
()
People
(Reporter: etienne, Assigned: gwagner)
Details
Attachments
(1 file, 1 obsolete file)
3.42 KB,
patch
|
bent.mozilla
:
review+
|
Details | Diff | Splinter Review |
A "contains" find with 699056123 will not match a contact with a 0699056123 phone number. Which is weird, since 0699056123 *does* contain 699056123. But a "contains" find of +33699056123 will match 0699056123, so I guess we're doing something smart on the platform side which might be a bit too smart. In the meantime all the contacts lookup from the Dialer are failing...
Reporter | ||
Updated•12 years ago
|
blocking-basecamp: --- → ?
Updated•12 years ago
|
Component: DOM: Core & HTML → DOM: Device Interfaces
Assignee | ||
Updated•12 years ago
|
Assignee: nobody → anygregor
Comment 1•12 years ago
|
||
We definitely need to fix this. Is it related to PhoneNumberJS?
blocking-basecamp: ? → +
Comment 2•12 years ago
|
||
Mass Modify: All un-milestoned, unresolved blocking-basecamp+ bugs are being moved into the C3 milestone. Note that the target milestone does not mean that these bugs can't be resolved prior to 12/10, rather C2 bugs should be prioritized ahead of C3 bugs.
Target Milestone: --- → B2G C3 (12dec-1jan)
Updated•12 years ago
|
Priority: -- → P2
Assignee | ||
Comment 3•12 years ago
|
||
Attachment #689274 -
Flags: review?(bent.mozilla)
Assignee | ||
Comment 4•12 years ago
|
||
Attachment #689274 -
Attachment is obsolete: true
Attachment #689274 -
Flags: review?(bent.mozilla)
Assignee | ||
Updated•12 years ago
|
Attachment #689422 -
Flags: review?(bent.mozilla)
Comment on attachment 689422 [details] [diff] [review] patch Review of attachment 689422 [details] [diff] [review]: ----------------------------------------------------------------- ::: dom/contacts/fallback/ContactDB.jsm @@ +260,5 @@ > if (digits && number.length != digits.length) { > digits = digits.join(''); > for(let i = 0; i < digits.length; i++) { > + let num = digits.substring(i, digits.length); > + if (contact.search[field].indexOf(num) < 0) { Instead of doing this n^2 stuff let's just add all the numbers to a jsobj and then enumerate it at the end? @@ +445,5 @@ > let tmp = typeof options.filterValue == "string" > ? options.filterValue.toLowerCase() > : options.filterValue.toString().toLowerCase(); > + if (key === 'tel') { > + let digits = options.filterValue.match(/\d/g); Shouldn't this be 'tmp.match(...)'?
Attachment #689422 -
Flags: review?(bent.mozilla) → review+
Assignee | ||
Comment 6•12 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/bf86988e2420
Comment 7•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/bf86988e2420
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Comment 8•12 years ago
|
||
https://hg.mozilla.org/releases/mozilla-aurora/rev/5e01b3def6e0 https://hg.mozilla.org/releases/mozilla-beta/rev/d14cad5e390a
You need to log in
before you can comment on or make changes to this bug.
Description
•