Skip to content

Commit

Permalink
remember this is for demos please be forgiving! we do NOT always have…
Browse files Browse the repository at this point in the history
… issuerId!!!
  • Loading branch information
gvelez17 committed Oct 26, 2024
1 parent cec2f83 commit 96d2f6e
Show file tree
Hide file tree
Showing 2 changed files with 4,439 additions and 4,342 deletions.
14 changes: 7 additions & 7 deletions src/middlewares/validators/claim.validator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ import { passToExpressErrorHandler } from "../../utils";
const claimPostSchema = Joi.object({
subject: Joi.string().required(),
claim: Joi.string().required(),
issuerId: Joi.string().allow(""),
object: Joi.string().allow(""),
issuerId: Joi.string().allow("", null),
object: Joi.string().allow("", null),
statement: Joi.string().allow(""),
aspect: Joi.string().allow(""),
aspect: Joi.string().allow("", null),
amt: Joi.alternatives().try(
Joi.string()
.allow("")
Expand All @@ -26,15 +26,15 @@ const claimPostSchema = Joi.object({
Joi.number()
),
name: Joi.string().required(),
howKnown: Joi.string().allow(""),
howKnown: Joi.string().allow("", null),
images: Joi.array().items(
Joi.object({
url: Joi.string().required(),
metadata: Joi.object().allow(null).pattern(/.*/, Joi.any()),
effectiveDate: Joi.date().allow(null),
digestMultibase: Joi.string().allow(null),
signature: Joi.string().required(),
owner: Joi.string().required(),
signature: Joi.string().allow(null),
owner: Joi.string().allow(null),
})
),
sourceURI: Joi.string().allow(""),
Expand Down Expand Up @@ -73,4 +73,4 @@ export const claimPostValidator = async (
err.statusCode = 400;
passToExpressErrorHandler(err, next);
}
};
};
Loading

0 comments on commit 96d2f6e

Please sign in to comment.