Skip to content

Commit

Permalink
♻️ (liquibase.ts): remove legacy mergeConfigWithDefaults method as it…
Browse files Browse the repository at this point in the history
… is no longer needed and simplify the configuration setup for Liquibase class
  • Loading branch information
jandroav committed Jun 20, 2024
1 parent 8ca991c commit 42fca30
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions src/liquibase.ts
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,6 @@ export class Liquibase {
* ```
*/
constructor(private config: LiquibaseConfig) {
this.mergeConfigWithDefaults(config);
this.commandHandler = new CommandHandler(this.config);
}

Expand Down Expand Up @@ -922,20 +921,6 @@ export class Liquibase {
return this.commandHandler.spawnChildProcess(commandString);
}

/**
* For now, we will assume Postgres is the 'default' database type.
* In the future we can be smarter about how we merge these configs.
*
* @param config User Provided `LiquibaseConfig`
*/
private mergeConfigWithDefaults(config: LiquibaseConfig) {
const defaults: LiquibaseConfig = {
...POSTGRESQL_DEFAULT_CONFIG,
liquibase: FileHelper.bundledLiquibasePath,
};
this.config = Object.assign({}, defaults, config);
}

/**
* LEGACY CODE END
**/
Expand Down

0 comments on commit 42fca30

Please sign in to comment.