Merge pull request #6042 from ToolJet/release/v2.4.4

Release v2.4.4
This commit is contained in:
Midhun G S 2023-04-14 17:09:56 +05:30 committed by GitHub
commit 17d5a82057
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 20 additions and 2 deletions

View file

@ -1 +1 @@
2.4.3
2.4.4

View file

@ -1 +1 @@
2.4.3
2.4.4

View file

@ -323,6 +323,24 @@ export class AppImportExportService {
if (!appEnvironments?.length) {
currentOrgEnvironments.map((env) => (appEnvironmentMapping[env.id] = env.id));
} else if (appEnvironments?.length && appEnvironments[0]?.appVersionId) {
const appVersionedEnvironments = appEnvironments.filter((appEnv) => appEnv.appVersionId === appVersion.id);
for (const currentOrgEnv of currentOrgEnvironments) {
const appEnvironment = appVersionedEnvironments.filter((appEnv) => appEnv.name === currentOrgEnv.name)[0];
if (appEnvironment) {
appEnvironmentMapping[appEnvironment.id] = currentOrgEnv.id;
} else {
const env = manager.create(AppEnvironment, {
organizationId: user.organizationId,
name: currentOrgEnv.name,
isDefault: currentOrgEnv.isDefault,
createdAt: new Date(),
updatedAt: new Date(),
});
await manager.save(env);
appEnvironmentMapping[env.id] = env.id;
}
}
} else {
//For apps imported on v2 where organizationId not available
for (const currentOrgEnv of currentOrgEnvironments) {