@adaas/a-server 0.0.27 → 0.0.29

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 A_RequestHelper = class _A_RequestHelper {
292
292
  let bodyType;
293
293
  switch (true) {
294
294
  case (!!context.contentType && context.contentType.includes("application/json")):
295
- parsedBody = JSON.parse(context.data);
295
+ parsedBody = JSON.parse(context.data || "{}");
296
296
  bodyType = "json";
297
297
  break;
298
298
  case (!!context.contentType && context.contentType.includes("application/x-www-form-urlencoded")):
@@ -1775,12 +1775,12 @@ __decorateClass([
1775
1775
  __decorateParam(0, A_Inject(A_Server))
1776
1776
  ], A_ServerLogger.prototype, "logStop", 1);
1777
1777
  var _a3, _b3, _c3, _d2, _e2;
1778
- var A_HttpServer = class extends A_Service {
1778
+ var _A_HttpServer = class _A_HttpServer extends A_Service {
1779
1779
  static get onBeforeRequest() {
1780
1780
  return (target, propertyKey, descriptor) => {
1781
1781
  return A_Feature.Extend({
1782
1782
  name: A_HttpServerFeatures.onBeforeRequest,
1783
- scope: [target.constructor]
1783
+ scope: [_A_HttpServer]
1784
1784
  })(target, propertyKey, descriptor);
1785
1785
  };
1786
1786
  }
@@ -1788,7 +1788,7 @@ var A_HttpServer = class extends A_Service {
1788
1788
  return (target, propertyKey, descriptor) => {
1789
1789
  return A_Feature.Extend({
1790
1790
  name: A_HttpServerFeatures.onRequest,
1791
- scope: [target.constructor]
1791
+ scope: [_A_HttpServer]
1792
1792
  })(target, propertyKey, descriptor);
1793
1793
  };
1794
1794
  }
@@ -1796,7 +1796,7 @@ var A_HttpServer = class extends A_Service {
1796
1796
  return (target, propertyKey, descriptor) => {
1797
1797
  return A_Feature.Extend({
1798
1798
  name: A_HttpServerFeatures.onAfterRequest,
1799
- scope: [target.constructor]
1799
+ scope: [_A_HttpServer]
1800
1800
  })(target, propertyKey, descriptor);
1801
1801
  };
1802
1802
  }
@@ -1945,21 +1945,22 @@ __decorateClass([
1945
1945
  __decorateParam(0, A_Inject(A_Polyfill)),
1946
1946
  __decorateParam(1, A_Dependency.Required()),
1947
1947
  __decorateParam(1, A_Inject(A_Config))
1948
- ], A_HttpServer.prototype, _e2, 1);
1948
+ ], _A_HttpServer.prototype, _e2, 1);
1949
1949
  __decorateClass([
1950
1950
  A_Feature.Extend(),
1951
1951
  __decorateParam(0, A_Inject(A_Config)),
1952
1952
  __decorateParam(1, A_Inject(A_ServerLogger))
1953
- ], A_HttpServer.prototype, _d2, 1);
1953
+ ], _A_HttpServer.prototype, _d2, 1);
1954
1954
  __decorateClass([
1955
1955
  A_Feature.Extend()
1956
- ], A_HttpServer.prototype, _c3, 1);
1956
+ ], _A_HttpServer.prototype, _c3, 1);
1957
1957
  __decorateClass([
1958
1958
  A_Feature.Extend()
1959
- ], A_HttpServer.prototype, _b3, 1);
1959
+ ], _A_HttpServer.prototype, _b3, 1);
1960
1960
  __decorateClass([
1961
1961
  A_Feature.Extend()
1962
- ], A_HttpServer.prototype, _a3, 1);
1962
+ ], _A_HttpServer.prototype, _a3, 1);
1963
+ var A_HttpServer = _A_HttpServer;
1963
1964
  var A_ServerError = class extends A_Error {
1964
1965
  constructor() {
1965
1966
  super(...arguments);