Closed Bug 1085313 Opened 10 years ago Closed 10 years ago

[Gaia] Refactor the error handler for icc.{set|unlock}CardLock API.

Categories

(Firefox OS Graveyard :: Gaia, defect)

x86_64
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
2.1 S7 (24Oct)

People

(Reporter: edgar, Assigned: edgar)

References

Details

Attachments

(1 file)

(deleted), text/x-github-pull-request
eragonj
: review+
alive
: review+
sfoster
: review+
Details
In bug 1083745, we would like to deprecate IccCardLockError.lockType. But Gaia gets lockType from IccCardLockError now, like https://github.com/mozilla-b2g/gaia/blob/master/apps/settings/js/simcard_dialog.js#L95-L128. let request = icc.unlockCardLock(lockType); request.onerror = function(evt) { lockType = evt.target.error.lockType; .... }; Actually the |evt.target.error.lockType| is just the same as the lockType passed by caller. We could simply rewrite the code as below, let request = icc.unlockCardLock(lockType); request.onerror = function(lockType, evt) { ..... }.bind(this, lockType); Thank you.
Edgar, what's the schedule for you to remove this lockType from Gecko ? I can take this first.
Assignee: nobody → ejchen
Flags: needinfo?(echen)
This bug blocks bug 1052825 which is a v2.2 P1 item for telephony team. I can help to take cover this if you don't have free buffer to do this. :) Thank you.
Flags: needinfo?(echen)
Sure Edgar, based on our offline discussion, let me redirect this bug to you first. Thanks !
Assignee: ejchen → echen
Attached file [mozilla-b2g:master] PR #25371 (deleted) —
Comment on attachment 8509155 [details] [mozilla-b2g:master] PR #25371 Hi EJ, may I have your review on Setting part?
Attachment #8509155 - Flags: review?(ejchen)
Comment on attachment 8509155 [details] [mozilla-b2g:master] PR #25371 Hi Alive, may I have your review on System part? Thank you
Attachment #8509155 - Flags: review?(alive)
Comment on attachment 8509155 [details] [mozilla-b2g:master] PR #25371 Hi sfoster, may I have your review for FTU part? Thank you.
Attachment #8509155 - Flags: review?(sfoster)
Comment on attachment 8509155 [details] [mozilla-b2g:master] PR #25371 +system part
Attachment #8509155 - Flags: review?(alive) → review+
Comment on attachment 8509155 [details] [mozilla-b2g:master] PR #25371 FTU part looks good to me. Looks like we have no test coverage for the retryCount property in the error in the FTU, I'm making a note to add that but its backfill and not necessary to land this.
Attachment #8509155 - Flags: review?(sfoster) → review+
Comment on attachment 8509155 [details] [mozilla-b2g:master] PR #25371 r+ for settings part. Thanks Edgar !!
Attachment #8509155 - Flags: review?(ejchen) → review+
Thanks to all of you for the review.
Status: NEW → RESOLVED
Closed: 10 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → 2.1 S7 (24Oct)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: