mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-06 18:27:19 +00:00
Merge pull request #3423 from Infisical/fix/getFolderIsImportedByThrow
Avoid throwing on getFolderIsImportedBy no folder found
This commit is contained in:
@@ -825,10 +825,7 @@ export const secretImportServiceFactory = ({
|
|||||||
);
|
);
|
||||||
|
|
||||||
const folder = await folderDAL.findBySecretPath(projectId, environment, secretPath);
|
const folder = await folderDAL.findBySecretPath(projectId, environment, secretPath);
|
||||||
if (!folder)
|
if (!folder) return [];
|
||||||
throw new NotFoundError({
|
|
||||||
message: `Folder with path '${secretPath}' in environment with slug '${environment}' not found`
|
|
||||||
});
|
|
||||||
|
|
||||||
const importedBy = await secretImportDAL.getFolderIsImportedBy(secretPath, folder.envId, environment, projectId);
|
const importedBy = await secretImportDAL.getFolderIsImportedBy(secretPath, folder.envId, environment, projectId);
|
||||||
const deepPaths: { path: string; folderId: string }[] = [];
|
const deepPaths: { path: string; folderId: string }[] = [];
|
||||||
|
|||||||
Reference in New Issue
Block a user