@cheetah.js/orm 0.1.31 → 0.1.32
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.
- package/dist/bun/index.js +108 -90
- package/dist/bun/index.js.map +16 -16
- package/package.json +2 -2
package/dist/bun/index.js
CHANGED
|
@@ -218325,7 +218325,7 @@ var PROPERTIES_METADATA = "cheetah:properties:metadata";
|
|
|
218325
218325
|
var PROPERTIES_RELATIONS = "cheetah:properties:relations";
|
|
218326
218326
|
var EVENTS_METADATA = "cheetah:events:metadata";
|
|
218327
218327
|
|
|
218328
|
-
//
|
|
218328
|
+
// /export/htdocs/p/framework/packages/core/dist/domain/provider-type.js
|
|
218329
218329
|
var ProviderType;
|
|
218330
218330
|
(function(ProviderType2) {
|
|
218331
218331
|
ProviderType2["ROUTES"] = "routes";
|
|
@@ -218334,7 +218334,7 @@ var ProviderType;
|
|
|
218334
218334
|
ProviderType2["CONTROLLER"] = "controller";
|
|
218335
218335
|
})(ProviderType || (ProviderType = {}));
|
|
218336
218336
|
|
|
218337
|
-
//
|
|
218337
|
+
// /export/htdocs/p/framework/packages/core/dist/domain/provider-scope.js
|
|
218338
218338
|
var ProviderScope;
|
|
218339
218339
|
(function(ProviderScope2) {
|
|
218340
218340
|
ProviderScope2["REQUEST"] = "request";
|
|
@@ -218342,33 +218342,17 @@ var ProviderScope;
|
|
|
218342
218342
|
ProviderScope2["SINGLETON"] = "singleton";
|
|
218343
218343
|
})(ProviderScope || (ProviderScope = {}));
|
|
218344
218344
|
|
|
218345
|
-
// /export/htdocs/p/framework/packages/core/dist/domain/provider-type.js
|
|
218346
|
-
var ProviderType2;
|
|
218347
|
-
(function(ProviderType3) {
|
|
218348
|
-
ProviderType3["ROUTES"] = "routes";
|
|
218349
|
-
ProviderType3["SERVICE"] = "service";
|
|
218350
|
-
ProviderType3["PROVIDER"] = "provider";
|
|
218351
|
-
ProviderType3["CONTROLLER"] = "controller";
|
|
218352
|
-
})(ProviderType2 || (ProviderType2 = {}));
|
|
218353
|
-
|
|
218354
|
-
// /export/htdocs/p/framework/packages/core/dist/domain/provider-scope.js
|
|
218355
|
-
var ProviderScope2;
|
|
218356
|
-
(function(ProviderScope3) {
|
|
218357
|
-
ProviderScope3["REQUEST"] = "request";
|
|
218358
|
-
ProviderScope3["INSTANCE"] = "instance";
|
|
218359
|
-
ProviderScope3["SINGLETON"] = "singleton";
|
|
218360
|
-
})(ProviderScope2 || (ProviderScope2 = {}));
|
|
218361
|
-
|
|
218362
218345
|
// /export/htdocs/p/framework/packages/core/dist/domain/provider.js
|
|
218363
218346
|
class Provider {
|
|
218364
|
-
type =
|
|
218347
|
+
type = ProviderType.PROVIDER;
|
|
218365
218348
|
deps = [];
|
|
218366
218349
|
instance;
|
|
218367
218350
|
_provide;
|
|
218368
218351
|
_useClass;
|
|
218352
|
+
_useValue;
|
|
218369
218353
|
hooks;
|
|
218370
218354
|
path;
|
|
218371
|
-
scope =
|
|
218355
|
+
scope = ProviderScope.SINGLETON;
|
|
218372
218356
|
children = [];
|
|
218373
218357
|
parent;
|
|
218374
218358
|
constructor(token, options = {}) {
|
|
@@ -218396,6 +218380,12 @@ class Provider {
|
|
|
218396
218380
|
}, {});
|
|
218397
218381
|
}
|
|
218398
218382
|
}
|
|
218383
|
+
get useValue() {
|
|
218384
|
+
return this._useValue;
|
|
218385
|
+
}
|
|
218386
|
+
set useValue(value) {
|
|
218387
|
+
this._useValue = value();
|
|
218388
|
+
}
|
|
218399
218389
|
get provide() {
|
|
218400
218390
|
return this._provide;
|
|
218401
218391
|
}
|
|
@@ -218480,7 +218470,7 @@ class ProviderControl extends Map {
|
|
|
218480
218470
|
}
|
|
218481
218471
|
}
|
|
218482
218472
|
createIfNotExists(key, options) {
|
|
218483
|
-
const type = options.type ||
|
|
218473
|
+
const type = options.type || ProviderType.PROVIDER;
|
|
218484
218474
|
if (!this.has(key)) {
|
|
218485
218475
|
const { model = Provider } = this.settings.get(type) || {};
|
|
218486
218476
|
const item = new model(key, options);
|
|
@@ -218497,9 +218487,9 @@ function registerProvider(provider3) {
|
|
|
218497
218487
|
}
|
|
218498
218488
|
return GlobalProvider.merge(provider3.provide, provider3);
|
|
218499
218489
|
}
|
|
218500
|
-
GlobalProvider.createRegistry(
|
|
218501
|
-
GlobalProvider.createRegistry(
|
|
218502
|
-
var registerController = GlobalProvider.createRegisterFn(
|
|
218490
|
+
GlobalProvider.createRegistry(ProviderType.CONTROLLER, Provider);
|
|
218491
|
+
GlobalProvider.createRegistry(ProviderType.ROUTES, Provider);
|
|
218492
|
+
var registerController = GlobalProvider.createRegisterFn(ProviderType.CONTROLLER);
|
|
218503
218493
|
// /export/htdocs/p/framework/packages/core/node_modules/globby/index.js
|
|
218504
218494
|
var import_merge2 = __toESM(require_merge2(), 1);
|
|
218505
218495
|
var import_fast_glob2 = __toESM(require_out4(), 1);
|
|
@@ -221458,7 +221448,7 @@ var InjectorService = InjectorService_1 = class InjectorService2 {
|
|
|
221458
221448
|
resolveControllers() {
|
|
221459
221449
|
if (!this.settings)
|
|
221460
221450
|
return {};
|
|
221461
|
-
const controllers = GlobalProvider.getByType(
|
|
221451
|
+
const controllers = GlobalProvider.getByType(ProviderType.CONTROLLER).filter((controller2) => !controller2.isChild());
|
|
221462
221452
|
let hydrateRoute = new Map;
|
|
221463
221453
|
for (const controller2 of controllers) {
|
|
221464
221454
|
let routes = Metadata.get(CONTROLLER_ROUTES, controller2.token);
|
|
@@ -221493,10 +221483,7 @@ var InjectorService = InjectorService_1 = class InjectorService2 {
|
|
|
221493
221483
|
if (controller2.children) {
|
|
221494
221484
|
const childrenRoutes = this.resolveChildrenRoutes(controller2.path ?? "", controller2.children, controllerMiddleware);
|
|
221495
221485
|
childrenRoutes.forEach((route) => {
|
|
221496
|
-
hydrateRoute.set(route.method.toLowerCase(), [
|
|
221497
|
-
...hydrateRoute.get(route.method.toLowerCase()) || [],
|
|
221498
|
-
route
|
|
221499
|
-
]);
|
|
221486
|
+
hydrateRoute.set(route.method.toLowerCase(), [...hydrateRoute.get(route.method.toLowerCase()) || [], route]);
|
|
221500
221487
|
});
|
|
221501
221488
|
}
|
|
221502
221489
|
}
|
|
@@ -221576,22 +221563,28 @@ var InjectorService = InjectorService_1 = class InjectorService2 {
|
|
|
221576
221563
|
if (provider3.instance)
|
|
221577
221564
|
return provider3.instance;
|
|
221578
221565
|
let scope = this.scopeOf(provider3);
|
|
221579
|
-
if (!provider3.useClass)
|
|
221566
|
+
if (!provider3.useClass && !provider3.useValue)
|
|
221580
221567
|
throw new Error("Provider not found.");
|
|
221581
221568
|
const deps = this.getConstructorDependencies(provider3.useClass);
|
|
221582
|
-
|
|
221569
|
+
let construct;
|
|
221570
|
+
if (provider3.useValue)
|
|
221571
|
+
construct = (deps2) => provider3.useValue;
|
|
221572
|
+
else
|
|
221573
|
+
construct = (deps2) => new provider3.useClass(...deps2);
|
|
221583
221574
|
let instance;
|
|
221584
221575
|
if (isRequestScope(provider3, deps, this)) {
|
|
221585
|
-
scope =
|
|
221576
|
+
scope = ProviderScope.REQUEST;
|
|
221586
221577
|
}
|
|
221587
|
-
|
|
221578
|
+
let services = [];
|
|
221579
|
+
if (!provider3.useValue)
|
|
221580
|
+
services = deps.filter((t) => !isPrimitiveType(t)).map((token) => this.invoke(getClassOrSymbol(token), locals));
|
|
221588
221581
|
instance = construct(services);
|
|
221589
221582
|
switch (scope) {
|
|
221590
|
-
case
|
|
221583
|
+
case ProviderScope.SINGLETON:
|
|
221591
221584
|
provider3.instance = instance;
|
|
221592
221585
|
this.container.addProvider(provider3.token, provider3);
|
|
221593
221586
|
break;
|
|
221594
|
-
case
|
|
221587
|
+
case ProviderScope.REQUEST:
|
|
221595
221588
|
const clone = provider3.clone();
|
|
221596
221589
|
clone.instance = instance;
|
|
221597
221590
|
locals.set(clone.token, clone);
|
|
@@ -221643,7 +221636,7 @@ var InjectorService = InjectorService_1 = class InjectorService2 {
|
|
|
221643
221636
|
return methodInfo;
|
|
221644
221637
|
}
|
|
221645
221638
|
scopeOf(provider3) {
|
|
221646
|
-
return provider3.scope ||
|
|
221639
|
+
return provider3.scope || ProviderScope.SINGLETON;
|
|
221647
221640
|
}
|
|
221648
221641
|
getConstructorDependencies(target, propertyKey) {
|
|
221649
221642
|
return Metadata.getOwn("override:ctor:design:paramtypes", target, propertyKey) || [...Metadata.getParamTypes(target, propertyKey)];
|
|
@@ -221663,12 +221656,7 @@ var InjectorService = InjectorService_1 = class InjectorService2 {
|
|
|
221663
221656
|
this.container.set(InjectorService_1, provider3);
|
|
221664
221657
|
}
|
|
221665
221658
|
removeUnknownProviders() {
|
|
221666
|
-
const defaults = [
|
|
221667
|
-
Context,
|
|
221668
|
-
InjectorService_1,
|
|
221669
|
-
DefaultRoutesCheetah,
|
|
221670
|
-
LoggerService
|
|
221671
|
-
];
|
|
221659
|
+
const defaults = [Context, InjectorService_1, DefaultRoutesCheetah, LoggerService];
|
|
221672
221660
|
this.applicationConfig.providers = this.applicationConfig.providers || [];
|
|
221673
221661
|
this.applicationConfig.providers.push(...defaults);
|
|
221674
221662
|
let hooks = Metadata.get(CONTROLLER_EVENTS, Reflect);
|
|
@@ -221789,7 +221777,7 @@ var Context = Context_1 = class Context2 {
|
|
|
221789
221777
|
}
|
|
221790
221778
|
};
|
|
221791
221779
|
Context = Context_1 = __decorate2([
|
|
221792
|
-
Injectable({ scope:
|
|
221780
|
+
Injectable({ scope: ProviderScope.REQUEST }),
|
|
221793
221781
|
__metadata("design:paramtypes", [])
|
|
221794
221782
|
], Context);
|
|
221795
221783
|
// /export/htdocs/p/framework/packages/core/dist/domain/LocalsContainer.js
|
|
@@ -222176,7 +222164,7 @@ function isRequestScope(provider4, deps, injector) {
|
|
|
222176
222164
|
const depProvider = injector.get(dep);
|
|
222177
222165
|
if (!depProvider)
|
|
222178
222166
|
return false;
|
|
222179
|
-
return depProvider.scope ===
|
|
222167
|
+
return depProvider.scope === ProviderScope.REQUEST;
|
|
222180
222168
|
});
|
|
222181
222169
|
}
|
|
222182
222170
|
// /export/htdocs/p/framework/packages/core/dist/utils/nameOf.js
|
|
@@ -222352,16 +222340,51 @@ LoggerService = __decorate4([
|
|
|
222352
222340
|
Service(),
|
|
222353
222341
|
__metadata3("design:paramtypes", [InjectorService])
|
|
222354
222342
|
], LoggerService);
|
|
222343
|
+
// ../../node_modules/balanced-match/
|
|
222344
|
+
function Entity(options) {
|
|
222345
|
+
return (target) => {
|
|
222346
|
+
const entities = Metadata.get(ENTITIES, Reflect) || [];
|
|
222347
|
+
entities.push({ target, options });
|
|
222348
|
+
Metadata.set(ENTITIES, entities, Reflect);
|
|
222349
|
+
};
|
|
222350
|
+
}
|
|
222351
|
+
// ../../node_m
|
|
222352
|
+
function getDefaultLength(type) {
|
|
222353
|
+
return null;
|
|
222354
|
+
}
|
|
222355
|
+
function toSnakeCase(propertyKey1) {
|
|
222356
|
+
propertyKey1 = propertyKey1[0].toLowerCase() + propertyKey1.slice(1);
|
|
222357
|
+
return propertyKey1.replace(/([A-Z])/g, "_$1").toLowerCase();
|
|
222358
|
+
}
|
|
222359
|
+
|
|
222360
|
+
// ../../node_modules/balanced-match/index.jsodules/minimatch
|
|
222361
|
+
var ProviderType2;
|
|
222362
|
+
(function(ProviderType3) {
|
|
222363
|
+
ProviderType3["ROUTES"] = "routes";
|
|
222364
|
+
ProviderType3["SERVICE"] = "service";
|
|
222365
|
+
ProviderType3["PROVIDER"] = "provider";
|
|
222366
|
+
ProviderType3["CONTROLLER"] = "controller";
|
|
222367
|
+
})(ProviderType2 || (ProviderType2 = {}));
|
|
222368
|
+
|
|
222369
|
+
// ../../node_modules/balanced-match/index.jsodules/minimatch/
|
|
222370
|
+
var ProviderScope2;
|
|
222371
|
+
(function(ProviderScope3) {
|
|
222372
|
+
ProviderScope3["REQUEST"] = "request";
|
|
222373
|
+
ProviderScope3["INSTANCE"] = "instance";
|
|
222374
|
+
ProviderScope3["SINGLETON"] = "singleton";
|
|
222375
|
+
})(ProviderScope2 || (ProviderScope2 = {}));
|
|
222376
|
+
|
|
222355
222377
|
// ../../node_modules/balanced-match/index.jsodules/mini
|
|
222356
222378
|
class Provider2 {
|
|
222357
|
-
type =
|
|
222379
|
+
type = ProviderType2.PROVIDER;
|
|
222358
222380
|
deps = [];
|
|
222359
222381
|
instance;
|
|
222360
222382
|
_provide;
|
|
222361
222383
|
_useClass;
|
|
222384
|
+
_useValue;
|
|
222362
222385
|
hooks;
|
|
222363
222386
|
path;
|
|
222364
|
-
scope =
|
|
222387
|
+
scope = ProviderScope2.SINGLETON;
|
|
222365
222388
|
children = [];
|
|
222366
222389
|
parent;
|
|
222367
222390
|
constructor(token, options = {}) {
|
|
@@ -222389,6 +222412,12 @@ class Provider2 {
|
|
|
222389
222412
|
}, {});
|
|
222390
222413
|
}
|
|
222391
222414
|
}
|
|
222415
|
+
get useValue() {
|
|
222416
|
+
return this._useValue;
|
|
222417
|
+
}
|
|
222418
|
+
set useValue(value) {
|
|
222419
|
+
this._useValue = value();
|
|
222420
|
+
}
|
|
222392
222421
|
get provide() {
|
|
222393
222422
|
return this._provide;
|
|
222394
222423
|
}
|
|
@@ -222473,7 +222502,7 @@ class ProviderControl5 extends Map {
|
|
|
222473
222502
|
}
|
|
222474
222503
|
}
|
|
222475
222504
|
createIfNotExists(key, options) {
|
|
222476
|
-
const type = options.type ||
|
|
222505
|
+
const type = options.type || ProviderType2.PROVIDER;
|
|
222477
222506
|
if (!this.has(key)) {
|
|
222478
222507
|
const { model = Provider2 } = this.settings.get(type) || {};
|
|
222479
222508
|
const item = new model(key, options);
|
|
@@ -222484,9 +222513,9 @@ class ProviderControl5 extends Map {
|
|
|
222484
222513
|
}
|
|
222485
222514
|
var GlobalProvider2 = new ProviderControl5;
|
|
222486
222515
|
// ../../node_modules/balanced-match/index.jsodules/minimatch/dist/cjs/unesc
|
|
222487
|
-
GlobalProvider2.createRegistry(
|
|
222488
|
-
GlobalProvider2.createRegistry(
|
|
222489
|
-
var registerController2 = GlobalProvider2.createRegisterFn(
|
|
222516
|
+
GlobalProvider2.createRegistry(ProviderType2.CONTROLLER, Provider2);
|
|
222517
|
+
GlobalProvider2.createRegistry(ProviderType2.ROUTES, Provider2);
|
|
222518
|
+
var registerController2 = GlobalProvider2.createRegisterFn(ProviderType2.CONTROLLER);
|
|
222490
222519
|
// /export/htdocs/p/framework/node_modules/globby/index.js
|
|
222491
222520
|
var import_merge22 = __toESM(require_merge2(), 1);
|
|
222492
222521
|
var import_fast_glob4 = __toESM(require_out4(), 1);
|
|
@@ -223115,7 +223144,7 @@ var InjectorService5 = InjectorService_12 = class InjectorService6 {
|
|
|
223115
223144
|
resolveControllers() {
|
|
223116
223145
|
if (!this.settings)
|
|
223117
223146
|
return {};
|
|
223118
|
-
const controllers = GlobalProvider.getByType(
|
|
223147
|
+
const controllers = GlobalProvider.getByType(ProviderType.CONTROLLER).filter((controller3) => !controller3.isChild());
|
|
223119
223148
|
let hydrateRoute = new Map;
|
|
223120
223149
|
for (const controller3 of controllers) {
|
|
223121
223150
|
let routes = Metadata.get(CONTROLLER_ROUTES, controller3.token);
|
|
@@ -223150,10 +223179,7 @@ var InjectorService5 = InjectorService_12 = class InjectorService6 {
|
|
|
223150
223179
|
if (controller3.children) {
|
|
223151
223180
|
const childrenRoutes = this.resolveChildrenRoutes(controller3.path ?? "", controller3.children, controllerMiddleware);
|
|
223152
223181
|
childrenRoutes.forEach((route) => {
|
|
223153
|
-
hydrateRoute.set(route.method.toLowerCase(), [
|
|
223154
|
-
...hydrateRoute.get(route.method.toLowerCase()) || [],
|
|
223155
|
-
route
|
|
223156
|
-
]);
|
|
223182
|
+
hydrateRoute.set(route.method.toLowerCase(), [...hydrateRoute.get(route.method.toLowerCase()) || [], route]);
|
|
223157
223183
|
});
|
|
223158
223184
|
}
|
|
223159
223185
|
}
|
|
@@ -223233,22 +223259,26 @@ var InjectorService5 = InjectorService_12 = class InjectorService6 {
|
|
|
223233
223259
|
if (provider6.instance)
|
|
223234
223260
|
return provider6.instance;
|
|
223235
223261
|
let scope = this.scopeOf(provider6);
|
|
223236
|
-
if (!provider6.useClass)
|
|
223262
|
+
if (!provider6.useClass && !provider6.useValue)
|
|
223237
223263
|
throw new Error("Provider not found.");
|
|
223238
223264
|
const deps = this.getConstructorDependencies(provider6.useClass);
|
|
223239
|
-
|
|
223265
|
+
let construct;
|
|
223266
|
+
if (provider6.useClass)
|
|
223267
|
+
construct = (deps2) => new provider6.useClass(...deps2);
|
|
223268
|
+
else
|
|
223269
|
+
construct = (deps2) => provider6.useValue;
|
|
223240
223270
|
let instance;
|
|
223241
223271
|
if (isRequestScope(provider6, deps, this)) {
|
|
223242
|
-
scope =
|
|
223272
|
+
scope = ProviderScope.REQUEST;
|
|
223243
223273
|
}
|
|
223244
223274
|
const services = deps.filter((t) => !isPrimitiveType(t)).map((token) => this.invoke(getClassOrSymbol(token), locals));
|
|
223245
223275
|
instance = construct(services);
|
|
223246
223276
|
switch (scope) {
|
|
223247
|
-
case
|
|
223277
|
+
case ProviderScope.SINGLETON:
|
|
223248
223278
|
provider6.instance = instance;
|
|
223249
223279
|
this.container.addProvider(provider6.token, provider6);
|
|
223250
223280
|
break;
|
|
223251
|
-
case
|
|
223281
|
+
case ProviderScope.REQUEST:
|
|
223252
223282
|
const clone = provider6.clone();
|
|
223253
223283
|
clone.instance = instance;
|
|
223254
223284
|
locals.set(clone.token, clone);
|
|
@@ -223300,7 +223330,7 @@ var InjectorService5 = InjectorService_12 = class InjectorService6 {
|
|
|
223300
223330
|
return methodInfo;
|
|
223301
223331
|
}
|
|
223302
223332
|
scopeOf(provider6) {
|
|
223303
|
-
return provider6.scope ||
|
|
223333
|
+
return provider6.scope || ProviderScope.SINGLETON;
|
|
223304
223334
|
}
|
|
223305
223335
|
getConstructorDependencies(target, propertyKey) {
|
|
223306
223336
|
return Metadata.getOwn("override:ctor:design:paramtypes", target, propertyKey) || [...Metadata.getParamTypes(target, propertyKey)];
|
|
@@ -223320,12 +223350,7 @@ var InjectorService5 = InjectorService_12 = class InjectorService6 {
|
|
|
223320
223350
|
this.container.set(InjectorService_12, provider6);
|
|
223321
223351
|
}
|
|
223322
223352
|
removeUnknownProviders() {
|
|
223323
|
-
const defaults = [
|
|
223324
|
-
Context,
|
|
223325
|
-
InjectorService_12,
|
|
223326
|
-
DefaultRoutesCheetah,
|
|
223327
|
-
LoggerService
|
|
223328
|
-
];
|
|
223353
|
+
const defaults = [Context, InjectorService_12, DefaultRoutesCheetah, LoggerService];
|
|
223329
223354
|
this.applicationConfig.providers = this.applicationConfig.providers || [];
|
|
223330
223355
|
this.applicationConfig.providers.push(...defaults);
|
|
223331
223356
|
let hooks2 = Metadata.get(CONTROLLER_EVENTS, Reflect);
|
|
@@ -223392,7 +223417,7 @@ var Context4 = Context_12 = class Context5 {
|
|
|
223392
223417
|
req = {};
|
|
223393
223418
|
headers = {};
|
|
223394
223419
|
locals = {};
|
|
223395
|
-
resultStatus;
|
|
223420
|
+
resultStatus = 200;
|
|
223396
223421
|
constructor() {
|
|
223397
223422
|
}
|
|
223398
223423
|
static async createFromRequest(url, request, server) {
|
|
@@ -223441,7 +223466,7 @@ var Context4 = Context_12 = class Context5 {
|
|
|
223441
223466
|
}
|
|
223442
223467
|
};
|
|
223443
223468
|
Context4 = Context_12 = __decorate6([
|
|
223444
|
-
Injectable({ scope:
|
|
223469
|
+
Injectable({ scope: ProviderScope.REQUEST }),
|
|
223445
223470
|
__metadata4("design:paramtypes", [])
|
|
223446
223471
|
], Context4);
|
|
223447
223472
|
// ../../node_modules/balanced-match/index.jsodules/mini
|
|
@@ -223622,6 +223647,9 @@ class Cheetah3 {
|
|
|
223622
223647
|
this.init();
|
|
223623
223648
|
this.createHttpServer(port);
|
|
223624
223649
|
}
|
|
223650
|
+
getHttpServer() {
|
|
223651
|
+
return this.server;
|
|
223652
|
+
}
|
|
223625
223653
|
getInjector() {
|
|
223626
223654
|
return this.injector;
|
|
223627
223655
|
}
|
|
@@ -223718,6 +223746,13 @@ var LoggerService3 = class LoggerService4 {
|
|
|
223718
223746
|
constructor(injector) {
|
|
223719
223747
|
this.injector = injector;
|
|
223720
223748
|
const pinoConfig = this.injector.applicationConfig.logger || {};
|
|
223749
|
+
pinoConfig["transport"] = pinoConfig.transport || {
|
|
223750
|
+
target: "pino-pretty",
|
|
223751
|
+
options: {
|
|
223752
|
+
colorize: true,
|
|
223753
|
+
ignore: "pid,hostname"
|
|
223754
|
+
}
|
|
223755
|
+
};
|
|
223721
223756
|
this.logger = import_pino2.default(pinoConfig);
|
|
223722
223757
|
}
|
|
223723
223758
|
info(message, ...args) {
|
|
@@ -223743,27 +223778,10 @@ LoggerService3 = __decorate8([
|
|
|
223743
223778
|
Service(),
|
|
223744
223779
|
__metadata6("design:paramtypes", [InjectorService])
|
|
223745
223780
|
], LoggerService3);
|
|
223746
|
-
// ../../node_modules/balanced-match/
|
|
223747
|
-
function Entity(options) {
|
|
223748
|
-
return (target) => {
|
|
223749
|
-
const entities = Metadata3.get(ENTITIES, Reflect) || [];
|
|
223750
|
-
entities.push({ target, options });
|
|
223751
|
-
Metadata3.set(ENTITIES, entities, Reflect);
|
|
223752
|
-
};
|
|
223753
|
-
}
|
|
223754
|
-
// ../../node_m
|
|
223755
|
-
function getDefaultLength(type) {
|
|
223756
|
-
return null;
|
|
223757
|
-
}
|
|
223758
|
-
function toSnakeCase(propertyKey1) {
|
|
223759
|
-
propertyKey1 = propertyKey1[0].toLowerCase() + propertyKey1.slice(1);
|
|
223760
|
-
return propertyKey1.replace(/([A-Z])/g, "_$1").toLowerCase();
|
|
223761
|
-
}
|
|
223762
|
-
|
|
223763
223781
|
// ../../node_modules/balanced-match
|
|
223764
223782
|
function Index(options) {
|
|
223765
223783
|
return (target, propertyKey) => {
|
|
223766
|
-
const indexes =
|
|
223784
|
+
const indexes = Metadata3.get("indexes", target.constructor) || [];
|
|
223767
223785
|
let index;
|
|
223768
223786
|
if (options && options.properties) {
|
|
223769
223787
|
const properties = options.properties;
|
|
@@ -223772,7 +223790,7 @@ function Index(options) {
|
|
|
223772
223790
|
index = { name: `${propertyKey}_index`, properties: [propertyKey] };
|
|
223773
223791
|
}
|
|
223774
223792
|
indexes.push(index);
|
|
223775
|
-
|
|
223793
|
+
Metadata3.set("indexes", indexes, target.constructor);
|
|
223776
223794
|
};
|
|
223777
223795
|
}
|
|
223778
223796
|
|
|
@@ -227612,4 +227630,4 @@ export {
|
|
|
227612
227630
|
AfterCreate
|
|
227613
227631
|
};
|
|
227614
227632
|
|
|
227615
|
-
//# debugId=
|
|
227633
|
+
//# debugId=D324EA0E9DAC3A1664756e2164756e21
|