Skip to content

Commit

Permalink
better
Browse files Browse the repository at this point in the history
  • Loading branch information
liyuheng55555 committed Dec 13, 2023
1 parent 80e9ccb commit b73b35d
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,15 @@ protected boolean preCheck() {
if (config.isIS_DOUBLE_WRITE()) {
dbConfigs.add(config.getANOTHER_DBConfig());
}
return cleanUpData(dbConfigs, measurement)
&& (!config.isCREATE_SCHEMA() || registerSchema(measurement));
if (!cleanUpData(dbConfigs, measurement)) {
return false;
}
if (config.isCREATE_SCHEMA()) {
if (!registerSchema(measurement)) {
return false;
}
}
return true;
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,15 @@ protected boolean preCheck() {
if (config.isIS_DOUBLE_WRITE()) {
dbConfigs.add(config.getANOTHER_DBConfig());
}
return cleanUpData(dbConfigs, measurement)
&& (!config.isCREATE_SCHEMA() || registerSchema(measurement));
if (!cleanUpData(dbConfigs, measurement)) {
return false;
}
if (config.isCREATE_SCHEMA()) {
if (!registerSchema(measurement)) {
return false;
}
}
return true;
}

@Override
Expand Down

0 comments on commit b73b35d

Please sign in to comment.