add validation

This commit is contained in:
Alex Holliday
2025-02-08 08:04:36 -08:00
parent d852388202
commit e4525b96c3

View File

@@ -71,6 +71,13 @@ class StatusPageController {
};
getStatusPageByUrl = async (req, res, next) => {
try {
await getStatusPageParamValidation.validateAsync(req.params);
} catch (error) {
next(handleValidationError(error, SERVICE_NAME));
return;
}
try {
const statusPage = await this.db.getStatusPageByUrl(req.params.url);
return res.success({