@spyglassmc/nbt 0.3.13 → 0.3.14

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.
@@ -95,7 +95,12 @@ export function typeDefinition(typeDef, options = {}) {
95
95
  }
96
96
  return [];
97
97
  },
98
- reportError: mcdoc.runtime.checker.getDefaultErrorReporter(ctx, (mcdoc.runtime.checker.getDefaultErrorRange)),
98
+ reportError: (error) => {
99
+ if (options.isPredicate && error.kind === 'invalid_collection_length') {
100
+ return;
101
+ }
102
+ mcdoc.runtime.checker.getDefaultErrorReporter(ctx, (mcdoc.runtime.checker.getDefaultErrorRange))(error);
103
+ },
99
104
  attachTypeInfo: (node, definition, desc = '') => {
100
105
  node.typeDef = definition;
101
106
  node.requireCanonical = options.isPredicate;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spyglassmc/nbt",
3
- "version": "0.3.13",
3
+ "version": "0.3.14",
4
4
  "type": "module",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",
@@ -25,8 +25,8 @@
25
25
  "url": "https://github.com/SpyglassMC/Spyglass/issues"
26
26
  },
27
27
  "dependencies": {
28
- "@spyglassmc/core": "0.4.10",
28
+ "@spyglassmc/core": "0.4.11",
29
29
  "@spyglassmc/locales": "0.3.8",
30
- "@spyglassmc/mcdoc": "0.3.13"
30
+ "@spyglassmc/mcdoc": "0.3.14"
31
31
  }
32
32
  }