@valbuild/core 0.60.4 → 0.60.6

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.
@@ -292,7 +292,7 @@ var KeyOfSchema = /*#__PURE__*/function (_Schema) {
292
292
  }, {
293
293
  key: "optional",
294
294
  value: function optional() {
295
- return new KeyOfSchema(this.schema, undefined, true);
295
+ return new KeyOfSchema(this.schema, this.sourcePath, true);
296
296
  }
297
297
  }, {
298
298
  key: "serialize",
@@ -303,7 +303,7 @@ var KeyOfSchema = /*#__PURE__*/function (_Schema) {
303
303
  }
304
304
  var serializedSchema = this.schema;
305
305
  if (!serializedSchema) {
306
- throw new Error("Cannot serialize oneOf schema with empty selector.");
306
+ throw new Error("Cannot serialize keyOf schema with empty selector.");
307
307
  }
308
308
  var values;
309
309
  switch (serializedSchema.type) {
@@ -317,7 +317,7 @@ var KeyOfSchema = /*#__PURE__*/function (_Schema) {
317
317
  values = Object.keys(serializedSchema.items);
318
318
  break;
319
319
  default:
320
- throw new Error("Cannot serialize oneOf schema with selector of type '".concat(serializedSchema.type, "'. keyOf must be used with a Val Module."));
320
+ throw new Error("Cannot serialize keyOf schema with selector of type '".concat(serializedSchema.type, "'. keyOf must be used with a Val Module."));
321
321
  }
322
322
  return {
323
323
  type: "keyOf",
@@ -292,7 +292,7 @@ var KeyOfSchema = /*#__PURE__*/function (_Schema) {
292
292
  }, {
293
293
  key: "optional",
294
294
  value: function optional() {
295
- return new KeyOfSchema(this.schema, undefined, true);
295
+ return new KeyOfSchema(this.schema, this.sourcePath, true);
296
296
  }
297
297
  }, {
298
298
  key: "serialize",
@@ -303,7 +303,7 @@ var KeyOfSchema = /*#__PURE__*/function (_Schema) {
303
303
  }
304
304
  var serializedSchema = this.schema;
305
305
  if (!serializedSchema) {
306
- throw new Error("Cannot serialize oneOf schema with empty selector.");
306
+ throw new Error("Cannot serialize keyOf schema with empty selector.");
307
307
  }
308
308
  var values;
309
309
  switch (serializedSchema.type) {
@@ -317,7 +317,7 @@ var KeyOfSchema = /*#__PURE__*/function (_Schema) {
317
317
  values = Object.keys(serializedSchema.items);
318
318
  break;
319
319
  default:
320
- throw new Error("Cannot serialize oneOf schema with selector of type '".concat(serializedSchema.type, "'. keyOf must be used with a Val Module."));
320
+ throw new Error("Cannot serialize keyOf schema with selector of type '".concat(serializedSchema.type, "'. keyOf must be used with a Val Module."));
321
321
  }
322
322
  return {
323
323
  type: "keyOf",
@@ -290,7 +290,7 @@ var KeyOfSchema = /*#__PURE__*/function (_Schema) {
290
290
  }, {
291
291
  key: "optional",
292
292
  value: function optional() {
293
- return new KeyOfSchema(this.schema, undefined, true);
293
+ return new KeyOfSchema(this.schema, this.sourcePath, true);
294
294
  }
295
295
  }, {
296
296
  key: "serialize",
@@ -301,7 +301,7 @@ var KeyOfSchema = /*#__PURE__*/function (_Schema) {
301
301
  }
302
302
  var serializedSchema = this.schema;
303
303
  if (!serializedSchema) {
304
- throw new Error("Cannot serialize oneOf schema with empty selector.");
304
+ throw new Error("Cannot serialize keyOf schema with empty selector.");
305
305
  }
306
306
  var values;
307
307
  switch (serializedSchema.type) {
@@ -315,7 +315,7 @@ var KeyOfSchema = /*#__PURE__*/function (_Schema) {
315
315
  values = Object.keys(serializedSchema.items);
316
316
  break;
317
317
  default:
318
- throw new Error("Cannot serialize oneOf schema with selector of type '".concat(serializedSchema.type, "'. keyOf must be used with a Val Module."));
318
+ throw new Error("Cannot serialize keyOf schema with selector of type '".concat(serializedSchema.type, "'. keyOf must be used with a Val Module."));
319
319
  }
320
320
  return {
321
321
  type: "keyOf",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@valbuild/core",
3
- "version": "0.60.4",
3
+ "version": "0.60.6",
4
4
  "private": false,
5
5
  "description": "Val - supercharged hard-coded content",
6
6
  "scripts": {