Fix MigrationRule changing when load consumer default value (#13237)

This commit is contained in:
Albumen Kevin 2023-10-20 15:32:01 +08:00 committed by GitHub
parent 58bf28f8c0
commit fc0f88f4f2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 3 deletions

View File

@ -166,9 +166,8 @@ public class MigrationRule {
*/
if (step == null) {
// initial step : APPLICATION_FIRST
step = MigrationStep.APPLICATION_FIRST;
step = Enum.valueOf(MigrationStep.class,
consumerURL.getParameter(MIGRATION_STEP_KEY, getDefaultStep(consumerURL, step.name())));
return Enum.valueOf(MigrationStep.class,
consumerURL.getParameter(MIGRATION_STEP_KEY, getDefaultStep(consumerURL, MigrationStep.APPLICATION_FIRST.name())));
}
return step;