mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
fixed test data
This commit is contained in:
committed by
Ekaterina Tuzova
parent
03eedbe662
commit
71d59e0d73
@@ -542,7 +542,7 @@ public class StudySerializationUtils {
|
||||
return stepOptions;
|
||||
}
|
||||
|
||||
private JsonObject convertToThirdVersion(JsonObject stepOptionsJson) {
|
||||
private static JsonObject convertToThirdVersion(JsonObject stepOptionsJson) {
|
||||
if (!stepOptionsJson.has(LAST_SUBTASK)) return stepOptionsJson;
|
||||
final int lastSubtaskIndex = stepOptionsJson.get(LAST_SUBTASK).getAsInt();
|
||||
if (lastSubtaskIndex == 0) return stepOptionsJson;
|
||||
@@ -554,7 +554,7 @@ public class StudySerializationUtils {
|
||||
}
|
||||
}
|
||||
final JsonArray descriptions = stepOptionsJson.getAsJsonArray(TEXTS);
|
||||
if (descriptions.size() > 0) {
|
||||
if (descriptions != null && descriptions.size() > 0) {
|
||||
final JsonObject fileWrapper = descriptions.get(0).getAsJsonObject();
|
||||
if (fileWrapper.has(NAME)) {
|
||||
replaceWithSubtask(fileWrapper);
|
||||
@@ -563,7 +563,7 @@ public class StudySerializationUtils {
|
||||
return stepOptionsJson;
|
||||
}
|
||||
|
||||
private void replaceWithSubtask(JsonObject fileWrapper) {
|
||||
private static void replaceWithSubtask(JsonObject fileWrapper) {
|
||||
final String file = fileWrapper.get(NAME).getAsString();
|
||||
final String extension = FileUtilRt.getExtension(file);
|
||||
final String name = FileUtil.getNameWithoutExtension(file);
|
||||
|
||||
Reference in New Issue
Block a user