- From: Zoltan Kis via GitHub <sysbot+gh@w3.org>
- Date: Thu, 29 Aug 2019 12:50:06 +0000
- To: public-web-nfc@w3.org
IMHO `toJSON()` will never return `undefined` unless we feed `undefined` to it, i.e. when `record.[[PayloadData]]` is `undefined`. The result of `JSON.stringify(undefined)` is `undefined`, but `JSON.parse(undefined)` will through (not valid JSON). In NFC specs the guiding field is the payload length, PAYLOAD might be there or might be missing. For writes, the current spec should be fine (when feeding `undefined` to writes). For reads, we should clarify the parse algorithms to be explicit about the use of `undefined`. -- GitHub Notification of comment by zolkis Please view or discuss this issue at https://github.com/w3c/web-nfc/issues/309#issuecomment-526169932 using your GitHub account
Received on Thursday, 29 August 2019 12:50:08 UTC