diff --git a/src/main/java/io/github/jhipster/online/domain/deserializer/YoRCDeserializer.java b/src/main/java/io/github/jhipster/online/domain/deserializer/YoRCDeserializer.java index 99c142ec..c288c286 100644 --- a/src/main/java/io/github/jhipster/online/domain/deserializer/YoRCDeserializer.java +++ b/src/main/java/io/github/jhipster/online/domain/deserializer/YoRCDeserializer.java @@ -23,23 +23,23 @@ public YoRC deserialize(JsonParser jp, DeserializationContext ctxt) throws IOExc JsonNode node = jp.getCodec().readTree(jp); String serverPort = getDefaultIfNull(node.get("serverPort"), "8080"); - String authenticationType = node.get("authenticationType").asText(); + String authenticationType = getDefaultIfNull(node.get("authenticationType"), ""); String cacheProvider = getDefaultIfNull(node.get("cacheProvider"), "no"); boolean enableHibernateCache = getDefaultIfNull(node.get("enableHibernateCache"), false); - boolean webSocket = node.get("websocket").asBoolean(); - String databaseType = node.get("databaseType").asText(); - String devDatabaseType = node.get("devDatabaseType").asText(); - String prodDatabaseType = node.get("prodDatabaseType").asText(); + boolean webSocket = getDefaultIfNull(node.get("websocket"), false); + String databaseType = getDefaultIfNull(node.get("databaseType"), ""); + String devDatabaseType = getDefaultIfNull(node.get("devDatabaseType"), ""); + String prodDatabaseType = getDefaultIfNull(node.get("prodDatabaseType"), ""); boolean searchEngine = getDefaultIfNull(node.get("searchEngine"), false); boolean messageBroker = getDefaultIfNull(node.get("messageBroker"), false); boolean serviceDiscoveryType = getDefaultIfNull(node.get("serviceDiscoveryType"), false); - String buildTool = node.get("buildTool").asText(); + String buildTool = getDefaultIfNull(node.get("buildTool"), ""); boolean enableSwaggerCodegen = getDefaultIfNull(node.get("enableSwaggerCodegen"), false); String clientFramework = getDefaultIfNull(node.get("clientFramework"), "none"); boolean useSass = getDefaultIfNull(node.get("useSass"), false); - String clientPackageManager = node.get("clientPackageManager").asText(); - String applicationType = node.get("applicationType").asText(); - boolean enableTranslation = node.get("enableTranslation").asBoolean(); + String clientPackageManager = getDefaultIfNull(node.get("clientPackageManager"), ""); + String applicationType = getDefaultIfNull(node.get("applicationType"), ""); + boolean enableTranslation = getDefaultIfNull(node.get("enableTranslation"), false); String nativeLanguage = getDefaultIfNull(node.get("nativeLanguage"), ""); boolean hasProtractor = false; boolean hasGatling = false;