mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-10-17 16:27:39 +00:00
feature: secret overview page pagination/optimizations
This commit is contained in:
@@ -160,10 +160,9 @@ export const useGetImportedSecretsAllEnvs = ({
|
||||
projectId,
|
||||
path
|
||||
}),
|
||||
queryFn: () => fetchImportedSecrets(projectId, env, path).catch(() => []),
|
||||
enabled: Boolean(projectId) && Boolean(env),
|
||||
// eslint-disable-next-line react-hooks/rules-of-hooks
|
||||
select: (data: TImportedSecrets[]) => {
|
||||
queryFn: async () => {
|
||||
const data = await fetchImportedSecrets(projectId, env, path).catch(() => []);
|
||||
|
||||
return data.map((el) => ({
|
||||
environment: el.environment,
|
||||
secretPath: el.secretPath,
|
||||
@@ -183,7 +182,8 @@ export const useGetImportedSecretsAllEnvs = ({
|
||||
};
|
||||
})
|
||||
}));
|
||||
}
|
||||
},
|
||||
enabled: Boolean(projectId) && Boolean(env)
|
||||
}))
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user