mirror of
https://github.com/NginxProxyManager/nginx-proxy-manager.git
synced 2025-12-16 20:43:24 +00:00
Moved certrbot plugin list to backend
frontend doesn't include when building in react version adds swagger for existing dns-providers endpoint
This commit is contained in:
@@ -24,16 +24,21 @@ const apiValidator = async (schema, payload /*, description*/) => {
|
||||
throw new errs.ValidationError("Payload is undefined");
|
||||
}
|
||||
|
||||
|
||||
const validate = ajv.compile(schema);
|
||||
|
||||
const valid = validate(payload);
|
||||
|
||||
|
||||
if (valid && !validate.errors) {
|
||||
return payload;
|
||||
}
|
||||
|
||||
|
||||
|
||||
const message = ajv.errorsText(validate.errors);
|
||||
const err = new errs.ValidationError(message);
|
||||
err.debug = [validate.errors, payload];
|
||||
err.debug = {validationErrors: validate.errors, payload};
|
||||
throw err;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user