@balena/odata-parser 4.0.0 → 4.1.0-build-bind-null-be4c53827082b1917a7de0174635d2c91cefb64e-1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,3 +1,14 @@
1
+ - commits:
2
+ - subject: Allow ['Null'] inside a bound list
3
+ hash: be4c53827082b1917a7de0174635d2c91cefb64e
4
+ body: ""
5
+ footer:
6
+ Change-type: minor
7
+ change-type: minor
8
+ author: Otavio Jacobi
9
+ version: 4.1.0
10
+ title: ""
11
+ date: 2025-02-04T15:32:17.311Z
1
12
  - commits:
2
13
  - subject: "feat: compile odata `in` to a abstract sql `eq any $listBind`"
3
14
  hash: e0c9da393753d8bb056f7a822a6a821af1274e35
@@ -8,7 +19,7 @@
8
19
  author: Otavio Jacobi
9
20
  version: 4.0.0
10
21
  title: ""
11
- date: 2025-01-29T09:30:54.766Z
22
+ date: 2025-01-29T15:24:40.161Z
12
23
  - commits:
13
24
  - subject: Update dependencies
14
25
  hash: e671fc822a9db4c4aa43fc5b3d46d7c9b2558700
package/CHANGELOG.md CHANGED
@@ -4,6 +4,11 @@ All notable changes to this project will be documented in this file
4
4
  automatically by Versionist. DO NOT EDIT THIS FILE MANUALLY!
5
5
  This project adheres to [Semantic Versioning](http://semver.org/).
6
6
 
7
+ # v4.1.0
8
+ ## (2025-02-04)
9
+
10
+ * Allow ['Null'] inside a bound list [Otavio Jacobi]
11
+
7
12
  # v4.0.0
8
13
  ## (2025-01-29)
9
14
 
package/odata-parser.js CHANGED
@@ -543,8 +543,16 @@ function peg$parse(input, options) {
543
543
  return peg$parseFilterByExpressionLoop()
544
544
  };
545
545
  var peg$f36 = function(bindings) {
546
- const indices = bindings.map((binding) => binding.bind);
547
- const bindValues = indices.map((index) => binds[index]);
546
+ const indices = [];
547
+ const bindValues = [];
548
+ for (const binding of bindings) {
549
+ if (binding?.bind !== undefined) {
550
+ indices.push(binding.bind);
551
+ bindValues.push(binds[binding.bind]);
552
+ } else {
553
+ bindValues.push(['Null']);
554
+ }
555
+ }
548
556
  binds.splice(indices[0], indices.length);
549
557
  return Bind('List', bindValues);
550
558
  };
@@ -347,8 +347,16 @@ GroupedPrimitive =
347
347
  spaces
348
348
  ')'
349
349
  {
350
- const indices = bindings.map((binding) => binding.bind);
351
- const bindValues = indices.map((index) => binds[index]);
350
+ const indices = [];
351
+ const bindValues = [];
352
+ for (const binding of bindings) {
353
+ if (binding?.bind !== undefined) {
354
+ indices.push(binding.bind);
355
+ bindValues.push(binds[binding.bind]);
356
+ } else {
357
+ bindValues.push(['Null']);
358
+ }
359
+ }
352
360
  binds.splice(indices[0], indices.length);
353
361
  return Bind('List', bindValues);
354
362
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@balena/odata-parser",
3
- "version": "4.0.0",
3
+ "version": "4.1.0-build-bind-null-be4c53827082b1917a7de0174635d2c91cefb64e-1",
4
4
  "description": "An OData parser written in OMeta",
5
5
  "main": "odata-parser.js",
6
6
  "scripts": {
@@ -39,6 +39,6 @@
39
39
  "npm": ">=8.1.0"
40
40
  },
41
41
  "versionist": {
42
- "publishedAt": "2025-01-29T09:30:54.889Z"
42
+ "publishedAt": "2025-02-04T15:32:17.442Z"
43
43
  }
44
44
  }