@ductape/sdk 0.1.156 → 0.1.158
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/apps/services/app.service.js +6 -0
- package/dist/apps/services/app.service.js.map +1 -1
- package/dist/apps/validators/joi-validators/update.appAction.validator.d.ts +1 -2
- package/dist/apps/validators/joi-validators/update.appAction.validator.js +4 -0
- package/dist/apps/validators/joi-validators/update.appAction.validator.js.map +1 -1
- package/dist/database/adapters/mongodb.adapter.js +6 -3
- package/dist/database/adapters/mongodb.adapter.js.map +1 -1
- package/dist/database/databases.service.js +9 -7
- package/dist/database/databases.service.js.map +1 -1
- package/dist/features/feature-executor.d.ts +2 -0
- package/dist/features/feature-executor.js +32 -3
- package/dist/features/feature-executor.js.map +1 -1
- package/dist/features/features.service.js +10 -19
- package/dist/features/features.service.js.map +1 -1
- package/dist/features/types/features.types.d.ts +2 -2
- package/dist/index.js +3 -0
- package/dist/index.js.map +1 -1
- package/dist/products/services/products.service.js +18 -1
- package/dist/products/services/products.service.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/productsBuilder.types.d.ts +2 -0
- package/dist/types/productsBuilder.types.js.map +1 -1
- package/package.json +1 -1
|
@@ -2987,7 +2987,24 @@ class ProductsBuilderService {
|
|
|
2987
2987
|
return components;
|
|
2988
2988
|
}
|
|
2989
2989
|
async fetchApp(tag, throwErrorIfExists = false) {
|
|
2990
|
-
|
|
2990
|
+
var _a;
|
|
2991
|
+
let component = null;
|
|
2992
|
+
try {
|
|
2993
|
+
component = await this.productApi.fetchProductComponentByTag(this.product_id, 'app', tag, this.getUserAccess());
|
|
2994
|
+
}
|
|
2995
|
+
catch (_b) {
|
|
2996
|
+
// Compatibility fallback below handles deployments that only index app_tag.
|
|
2997
|
+
}
|
|
2998
|
+
if (!component) {
|
|
2999
|
+
const normalized = tag.toLowerCase();
|
|
3000
|
+
const apps = await this.fetchApps();
|
|
3001
|
+
component = (_a = apps.find((app) => {
|
|
3002
|
+
var _a, _b, _c;
|
|
3003
|
+
return String((_a = app.access_tag) !== null && _a !== void 0 ? _a : '').toLowerCase() === normalized
|
|
3004
|
+
|| String((_b = app.app_tag) !== null && _b !== void 0 ? _b : '').toLowerCase() === normalized
|
|
3005
|
+
|| String((_c = app.tag) !== null && _c !== void 0 ? _c : '').toLowerCase() === normalized;
|
|
3006
|
+
})) !== null && _a !== void 0 ? _a : null;
|
|
3007
|
+
}
|
|
2991
3008
|
if (!component && throwErrorIfExists)
|
|
2992
3009
|
throw new Error(`App ${tag} not found`);
|
|
2993
3010
|
return component;
|