Skip to content

Commit 5679bb3

Browse files
committed
5.0.0
1 parent c006ce9 commit 5679bb3

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

README.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,15 @@ see [JSON Patch (RFC6902)](#json-patch-rfc6902) below.
122122
I'm not going to copy & paste my relatively descriptive commit messages into groups here;
123123
rather, these are just the changes that merited major version bumps:
124124

125+
### `4.x.x``5.0.0` (2021-12-15)
126+
127+
* Short-circuits JSON pointer traversal over the prototype-polluting tokens `__proto__`, `constructor`, and `prototype`. I.e., `/a/__proto__/b` and `/a/b` evaluate to the same thing.
128+
This is in violation of the spec,
129+
which makes no special provisions for this idiosyncrasy of the JavaScript language,
130+
but AFAIK there's no way to strictly comply with the spec in JavaScript.
131+
It would probably be more correct to throw an error in those cases,
132+
but this 'solution' feels less disruptive / more in line with workarounds implemented by other libraries.
133+
125134
### `3.x.x``4.0.0` (2020-07-27)
126135

127136
* Potential performance regression due to consolidating separate `compare(a, b): boolean` and `diff(a, b): Operation[]` logic into basically defining `compare(a, b)` as `!diff(a, b).length` (i.e., `diff(a, b)` returns empty array).

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "rfc6902",
3-
"version": "4.0.2",
3+
"version": "5.0.0",
44
"description": "Complete implementation of RFC6902 (patch and diff)",
55
"keywords": [
66
"json",

0 commit comments

Comments
 (0)