@forklaunch/core 1.6.0 → 1.6.2
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/lib/persistence/index.js
CHANGED
|
@@ -1277,11 +1277,12 @@ function escapeSqlString(value) {
|
|
|
1277
1277
|
|
|
1278
1278
|
// src/persistence/tenantEm.ts
|
|
1279
1279
|
function wrapEmWithTenantContext(em, tenantId) {
|
|
1280
|
-
if (
|
|
1280
|
+
if (tenantId === void 0) {
|
|
1281
1281
|
return em;
|
|
1282
1282
|
}
|
|
1283
|
-
|
|
1284
|
-
|
|
1283
|
+
if (tenantId) {
|
|
1284
|
+
em.setFilterParams("tenant", { tenantId });
|
|
1285
|
+
}
|
|
1285
1286
|
return new Proxy(em, {
|
|
1286
1287
|
get(target, prop, receiver) {
|
|
1287
1288
|
const value = Reflect.get(target, prop, receiver);
|