Closed Bug 1059102 Opened 10 years ago Closed 10 years ago

B2G NFC: Better logging in (un)RegisterPeerTarget

Categories

(Firefox OS Graveyard :: NFC, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
2.1 S3 (29aug)

People

(Reporter: allstars.chh, Assigned: allstars.chh)

References

Details

(Whiteboard: [p=1])

Attachments

(3 files, 1 obsolete file)

Right now when app set onpeeready callback, we didn't show which appId registers this.

Also currentPeerAppId is set when checkP2PRegisterion, however I think it should be set in notifyUserAcceptedP2P.
Whiteboard: [good first bug]
I'll move handling currentPeerAppId in Bug 1055960.
Also I'd do the following renaming
1. rename msg[name] to message, as these unconsistent naming rule actually causes several typo.
2. rename message.json to message.data, as from http://lxr.mozilla.org/mozilla-central/source/content/base/public/nsIMessageManager.idl#185, the json field is deprecated.
Assignee: nobody → allstars.chh
Summary: B2G NFC: Betting logging in (un)RegisterPeerTarget and set currentPeerAppId properly → B2G NFC: Betting logging in (un)RegisterPeerTarget
Whiteboard: [good first bug]
Whiteboard: [p=1]
Target Milestone: --- → 2.1 S3 (29aug)
Attachment #8479749 - Flags: review?(dlee) → review+
Attachment #8479750 - Flags: review?(dlee) → review+
Comment on attachment 8479751 [details] [diff] [review]
Part 3: rename json to data.

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

Looks good, thanks!
Attachment #8479751 - Flags: review?(dlee) → review+
Comment on attachment 8479749 [details] [diff] [review]
Part 1: add logging

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

::: dom/nfc/gonk/Nfc.js
@@ +484,3 @@
>     */
>    receiveMessage: function receiveMessage(message) {
> +    debug("Received '" + JSON.stringify(message) + "' message from gMessageManager");

this line should be removed since we already printed this in line 240.
Summary: B2G NFC: Betting logging in (un)RegisterPeerTarget → B2G NFC: Better logging in (un)RegisterPeerTarget
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: