s2cfgtojson 3.2.10 → 3.2.12

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.
Files changed (2) hide show
  1. package/Struct.mts +1 -4
  2. package/package.json +1 -1
package/Struct.mts CHANGED
@@ -77,9 +77,6 @@ export class Struct {
77
77
  }
78
78
 
79
79
  addNode(value: any, key?: string | number): this {
80
- if (this.__internal__.isArray !== true) {
81
- throw new Error("Cannot add node to non-array struct.");
82
- }
83
80
  if (key === undefined) {
84
81
  const nextIndex = Object.keys(this)
85
82
  .map((k) => parseInt(k))
@@ -339,7 +336,7 @@ export function parseKey(key: string, parent: Struct, index: number) {
339
336
  normKey = extractKeyFromBrackets(key);
340
337
 
341
338
  if (normKey === "*") {
342
- parent.__internal__.useAsterisk = true;
339
+ // parent.__internal__.useAsterisk = true; never use asterisk for space-saving reasons
343
340
  return Object.keys(parent).length - 1;
344
341
  }
345
342
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "s2cfgtojson",
3
- "version": "3.2.10",
3
+ "version": "3.2.12",
4
4
  "description": "Converts Stalker 2 Cfg file into POJOs",
5
5
  "keywords": [
6
6
  "stalker",