Skip to content

Commit

Permalink
Merge pull request #172 from mdenet/fix/schema-validation-missing-file
Browse files Browse the repository at this point in the history
Added missing schema files to the ActivityConfigValidator
  • Loading branch information
barnettwilliam authored Feb 6, 2024
2 parents 4a4ded4 + 42e7a86 commit 8b4ec0a
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion platform/src/ActivityConfigValidator.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,16 @@ const schemaActivtyConfig = require('../schemas/activity-config.schema.json');
const schemaLayout = require('../schemas/layout.schema.json');
const schemaAction = require('../schemas/action.schema.json');
const schemaPanel = require('../schemas/panel.schema.json');
const schemaButton = require( '../schemas/button.schema.json');
const schemaRef = require( '../schemas/ref.schema.json');


class ActivityConfigValidator {

validate;

constructor() {
const schemaValidator = new Ajv({allErrors: true, schemas: [schemaActivtyConfig, schemaLayout, schemaAction, schemaPanel]});
const schemaValidator = new Ajv({allErrors: true, schemas: [schemaActivtyConfig, schemaLayout, schemaAction, schemaPanel, schemaButton, schemaRef]});
this.validate = schemaValidator.getSchema("https://mde-network.com/ep/activity-config.schema.json"); // id from local schema file
}

Expand Down

0 comments on commit 8b4ec0a

Please sign in to comment.