fixed checkstyle

This commit is contained in:
maverickstuder 2024-03-19 12:27:19 +01:00
parent 07b092c5a0
commit 0c8754c130

View File

@ -58,11 +58,12 @@ public class TenantMongoLiquibaseExecutor implements InitializingBean {
try (MongoLiquibaseDatabase database = (MongoLiquibaseDatabase) DatabaseFactory.getInstance()
.openDatabase(mongoUrl, mongoDBConnection.getUsername(), encryptionService.decrypt(mongoDBConnection.getPassword()), null, null)) {
Liquibase liquibase = new Liquibase(tenantLiquibaseProperties.getChangeLog(), new ClassLoaderResourceAccessor(), database);
Contexts contexts = new Contexts(tenantLiquibaseProperties.getContexts());
List<ChangeSet> changeSetsList = liquibase.listUnrunChangeSets(contexts, null);
if (!changeSetsList.isEmpty()) {
liquibase.update(contexts);
try (Liquibase liquibase = new Liquibase(tenantLiquibaseProperties.getChangeLog(), new ClassLoaderResourceAccessor(), database)) {
Contexts contexts = new Contexts(tenantLiquibaseProperties.getContexts());
List<ChangeSet> changeSetsList = liquibase.listUnrunChangeSets(contexts, null);
if (!changeSetsList.isEmpty()) {
liquibase.update(contexts);
}
}
} catch (Exception e) {