applied downloadable checkbox on submit of new appeal

This commit is contained in:
2026-03-16 13:58:02 +00:00
parent 72eafd0a8e
commit 7c84344d5d
9 changed files with 189 additions and 57 deletions
+8 -2
View File
@@ -11,7 +11,13 @@ ApiProxy.get(async (req, res) => {
return res.status(401).json();
}
const queryPath = req.query.path;
const rawQueryPath = req.query.path;
const queryPath =
typeof rawQueryPath === "string"
? rawQueryPath.split("?")[0]
: rawQueryPath;
const allowedPrefix = [
"/api/endpoint/getportallogin_api",
"/api/endpoint/deletemyrepresentations_api",
@@ -36,7 +42,7 @@ ApiProxy.get(async (req, res) => {
return res.status(400).json();
}
return res.status(200).json({ hash: hashAPIPath(queryPath) });
return res.status(200).json({ hash: hashAPIPath(rawQueryPath) });
});
export default ApiProxy;