Keep existing config we don't have fields for (#3639)
This commit is contained in:
parent
44436f5935
commit
37afe07bd5
1 changed files with 9 additions and 3 deletions
|
@ -162,8 +162,8 @@ export default function DetailSettings() {
|
|||
[]
|
||||
);
|
||||
|
||||
const save = async (provider?: IdentityProviderRepresentation) => {
|
||||
const p = provider || getValues();
|
||||
const save = async (savedProvider?: IdentityProviderRepresentation) => {
|
||||
const p = savedProvider || getValues();
|
||||
if (p.config?.authnContextClassRefs)
|
||||
p.config.authnContextClassRefs = JSON.stringify(
|
||||
p.config.authnContextClassRefs
|
||||
|
@ -172,10 +172,16 @@ export default function DetailSettings() {
|
|||
p.config.authnContextDeclRefs = JSON.stringify(
|
||||
p.config.authnContextDeclRefs
|
||||
);
|
||||
|
||||
try {
|
||||
await adminClient.identityProviders.update(
|
||||
{ alias },
|
||||
{ ...p, alias, providerId }
|
||||
{
|
||||
...p,
|
||||
config: { ...provider?.config, ...p.config },
|
||||
alias,
|
||||
providerId,
|
||||
}
|
||||
);
|
||||
addAlert(t("updateSuccess"), AlertVariant.success);
|
||||
} catch (error) {
|
||||
|
|
Loading…
Reference in a new issue