diff --git a/generator/src/main/java/dev/cdevents/generator/CDEventsGenerator.java b/generator/src/main/java/dev/cdevents/generator/CDEventsGenerator.java index 1e8d59e..c370fdd 100644 --- a/generator/src/main/java/dev/cdevents/generator/CDEventsGenerator.java +++ b/generator/src/main/java/dev/cdevents/generator/CDEventsGenerator.java @@ -104,7 +104,7 @@ private static SchemaData buildCDEventDataFromJsonSchema(File file) { JsonNode contextNode = rootNode.get("properties").get("context").get("properties"); JsonNode subjectNode = rootNode.get("properties").get("subject").get("properties"); String schemaURL = rootNode.get("$id").asText(); - boolean isCustomEvent = schemaURL.endsWith("custom"); + boolean isCustomEvent = schemaURL.endsWith("schema/custom"); schemaData.setSchemaURL(schemaURL); schemaData.setBaseURI(schemaURL.substring(0, schemaURL.lastIndexOf("/") + 1));