RFC Errata


Errata Search

 
Source of RFC  
Summary Table Full Records

RFC 6902, "JavaScript Object Notation (JSON) Patch", April 2013

Source of RFC: appsawg (app)

Errata ID: 5239
Status: Rejected
Type: Technical
Publication Format(s) : TEXT

Reported By: Grzegorz Olszewski
Date Reported: 2018-01-19
Rejected by: Barry Leiba
Date Rejected: 2020-12-09

Section A.16 says:

An example target JSON document:

   { "foo": ["bar"] }

   A JSON Patch document:

   [
     { "op": "add", "path": "/foo/-", "value": ["abc", "def"] }
   ]

   The resulting JSON document:

   { "foo": ["bar", ["abc", "def"]] }

It should say:

An example target JSON document:

   { "foo": ["bar"] }

   A JSON Patch document:

   [
     { "op": "add", "path": "/foo/-", "value": ["abc", "def"] }
   ]

   The resulting JSON document:

   { "foo": ["bar", "abc", "def"] }

Notes:

surplus square brackets in resulting JSON document
--VERIFIER NOTES--
The example is correct as written: the value to be added to the array is itself an array, so the new element is ["abc", "def"].

Report New Errata