@lwrjs/server 0.17.2-alpha.1 → 0.17.2-alpha.3

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.
@@ -54,7 +54,7 @@ function createInternalServer(serverType = "express", options = {}) {
54
54
  const fsAppServer = new import_fs_server.FsInternalServer(options);
55
55
  return fsAppServer;
56
56
  }
57
- throw (0, import_diagnostics.createSingleDiagnosticError)({description: import_diagnostics.descriptions.CONFIG_PARSER.INVALID_PROPERTY("serverType", serverType)}, import_diagnostics.LwrConfigValidationError);
57
+ throw new import_diagnostics.LwrConfigError(import_diagnostics.descriptions.CONFIG.INVALID_PROPERTY("serverType", serverType));
58
58
  }
59
59
  function mockMiddlewareRequest(req) {
60
60
  return new import_express_request.default(req);
package/build/es/index.js CHANGED
@@ -4,7 +4,7 @@ import ExpressResponse from './express/express-response.js';
4
4
  import KoaInternalServer from './koa/koa-server.js';
5
5
  import { FsInternalServer, LwrFsKoa } from './fs/fs-server.js';
6
6
  import { getTracer, CoreSpan } from '@lwrjs/instrumentation';
7
- import { createSingleDiagnosticError, descriptions, logger, LwrConfigValidationError, } from '@lwrjs/diagnostics';
7
+ import { descriptions, logger, LwrConfigError } from '@lwrjs/diagnostics';
8
8
  function createInternalServer(serverType = 'express', options = {}) {
9
9
  process.on('unhandledRejection', (err) => {
10
10
  // creating immediately closed span to mark the unhandled rejection
@@ -24,7 +24,7 @@ function createInternalServer(serverType = 'express', options = {}) {
24
24
  const fsAppServer = new FsInternalServer(options);
25
25
  return fsAppServer;
26
26
  }
27
- throw createSingleDiagnosticError({ description: descriptions.CONFIG_PARSER.INVALID_PROPERTY('serverType', serverType) }, LwrConfigValidationError);
27
+ throw new LwrConfigError(descriptions.CONFIG.INVALID_PROPERTY('serverType', serverType));
28
28
  }
29
29
  // Functions for testing
30
30
  function mockMiddlewareRequest(req) {
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },
7
- "version": "0.17.2-alpha.1",
7
+ "version": "0.17.2-alpha.3",
8
8
  "homepage": "https://developer.salesforce.com/docs/platform/lwr/overview",
9
9
  "repository": {
10
10
  "type": "git",
@@ -37,16 +37,16 @@
37
37
  "build": "tsc -b"
38
38
  },
39
39
  "devDependencies": {
40
- "@lwrjs/types": "0.17.2-alpha.1",
40
+ "@lwrjs/types": "0.17.2-alpha.3",
41
41
  "@types/koa-compress": "^4.0.6",
42
42
  "@types/koa__router": "^8.0.4",
43
43
  "jest-express": "^1.12.0"
44
44
  },
45
45
  "dependencies": {
46
46
  "@koa/router": "^10.0.0",
47
- "@lwrjs/diagnostics": "0.17.2-alpha.1",
48
- "@lwrjs/instrumentation": "0.17.2-alpha.1",
49
- "@lwrjs/shared-utils": "0.17.2-alpha.1",
47
+ "@lwrjs/diagnostics": "0.17.2-alpha.3",
48
+ "@lwrjs/instrumentation": "0.17.2-alpha.3",
49
+ "@lwrjs/shared-utils": "0.17.2-alpha.3",
50
50
  "@types/express": "^4.17.21",
51
51
  "@types/koa": "^2.15.0",
52
52
  "express": "^4.20.0",
@@ -56,5 +56,5 @@
56
56
  "engines": {
57
57
  "node": ">=18.0.0"
58
58
  },
59
- "gitHead": "bba15ca717a242b0375decaa378af06bdee813b5"
59
+ "gitHead": "43757693dfca356cff105d4896a7a3cbf11ac017"
60
60
  }