mirror of
https://github.com/awatertrevi/infisical.git
synced 2026-09-22 13:39:35 +00:00
Fix SshHostsTable component
This commit is contained in:
@@ -107,16 +107,20 @@ export const SshHostsTable = ({ handlePopUpOpen }: Props) => {
|
||||
{} as Record<string, Set<string>>
|
||||
);
|
||||
|
||||
const entriesFromHost = hostMappings.map(({ loginUser, allowedPrincipals }) => ({
|
||||
loginUser,
|
||||
source: LoginMappingSource.HOST,
|
||||
usernames: allowedPrincipals.usernames
|
||||
}));
|
||||
const entriesFromHost = hostMappings.map(
|
||||
({ loginUser, allowedPrincipals }) => ({
|
||||
loginUser,
|
||||
source: LoginMappingSource.HOST,
|
||||
usernames: allowedPrincipals.usernames
|
||||
})
|
||||
);
|
||||
|
||||
const entriesFromGroup = groupMappings
|
||||
.map(({ loginUser, allowedPrincipals }) => {
|
||||
const existing = hostLoginUserToPrincipals[loginUser] || new Set();
|
||||
const filteredUsernames = allowedPrincipals.usernames.filter((u) => !existing.has(u));
|
||||
const filteredUsernames = allowedPrincipals.usernames.filter(
|
||||
(u) => !existing.has(u)
|
||||
);
|
||||
return filteredUsernames.length > 0
|
||||
? {
|
||||
loginUser,
|
||||
@@ -233,8 +237,4 @@ export const SshHostsTable = ({ handlePopUpOpen }: Props) => {
|
||||
</TableContainer>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
</TableContainer>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user