fix(folders): changed to secret path in controllers for get by path op

This commit is contained in:
akhilmhdh
2023-06-04 13:26:20 +05:30
parent 58d3f3945a
commit e74cc471db

View File

@@ -661,7 +661,7 @@ export const getSecrets = async (req: Request, res: Response) => {
if (folders && secretPath) {
if (!folders) throw BadRequestError({ message: "Folder not found" });
const folder = getFolderByPath(folders.nodes, folderId as string);
const folder = getFolderByPath(folders.nodes, secretPath as string);
if (!folder) {
throw BadRequestError({ message: "Secret path not found" });
}