diff --git a/src/main/java/org/webjars/RequireJS.java b/src/main/java/org/webjars/RequireJS.java index c703b59..af9b4d5 100644 --- a/src/main/java/org/webjars/RequireJS.java +++ b/src/main/java/org/webjars/RequireJS.java @@ -135,7 +135,10 @@ public static String generateSetupJavaScript(@Nonnull Collection prefixe // default to the new pom.xml meta-data way ObjectNode webJarObjectNode = getWebJarSetupJson(webJar, prefixesWithVersion); if ((webJarObjectNode != null ? webJarObjectNode.size() : 0) == 0) { - webJarConfigsString.append('\n').append(getWebJarConfig(webJar)); + String legacyWebJarConfig = getWebJarConfig(webJar); + if (legacyWebJarConfig != null) { + webJarConfigsString.append('\n').append(legacyWebJarConfig); + } } else { requireJsConfigs.add(webJarObjectNode.toString()); }