Commit a076535b authored by Christina's avatar Christina
Browse files

return null in migration

parent 425a317b
Pipeline #876142 passed with stages
in 138 minutes and 21 seconds
......@@ -31,7 +31,10 @@ public class IOVadere {
public static Scenario fromJson(String json) throws IOException, IllegalArgumentException {
try {
JsonMigrationAssistant migrationAssistant = (JsonMigrationAssistant) MigrationAssistant.getNewInstance(MigrationOptions.defaultOptions());
json = migrationAssistant.migrateScenarioFile(json, Version.latest());
String migrationResult = migrationAssistant.migrateScenarioFile(json, Version.latest());
if (migrationResult != null){
json = migrationResult;
}
}
catch (MigrationException migrationException){
migrationException.printStackTrace();
......
......@@ -102,7 +102,7 @@ public class JsonMigrationAssistant extends MigrationAssistant {
migrationLogger.info("Nothing to do current version and target version match");
logger.info(migrationLogger.last());
restLog();
return json;
return null;
}
JsonNode transformedNode = node;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment