Commit fc11375d authored by Isuru Liyanage's avatar Isuru Liyanage
Browse files

add graph_restriction custom keyword to bio-validator

parent ed81d9ff
......@@ -40,4 +40,4 @@
}
},
"type": "object"
}
\ No newline at end of file
}
......@@ -2,12 +2,14 @@ const logger = require("./winston");
const ValidationError = require("./model/validation-error");
const AppError = require("./model/application-error");
const BioValidator = require("./bio-validator");
const GraphRestriction = require("./keywords/graph_restriction");
const { isChildTermOf, isValidTerm, isValidTaxonomy } = require("./keywords");
const validator = new BioValidator([
new isChildTermOf(null, "https://www.ebi.ac.uk/ols/api/search?q="),
new isValidTerm(null, "https://www.ebi.ac.uk/ols/api/search?q="),
new isValidTaxonomy(null)
new isValidTaxonomy(null),
new GraphRestriction(null, "https://www.ebi.ac.uk/ols/api")
]);
function convertToValidationErrors(ajvErrorObjects) {
......
File mode changed from 100644 to 100755
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment