Convert claims back to object (#3363)
This commit is contained in:
parent
6c57312273
commit
aa7acda01e
1 changed files with 2 additions and 3 deletions
|
@ -69,9 +69,7 @@ export default function AddMapper() {
|
||||||
useState<IdentityProviderMapperTypeRepresentation>();
|
useState<IdentityProviderMapperTypeRepresentation>();
|
||||||
|
|
||||||
const save = async (idpMapper: IdentityProviderMapperRepresentation) => {
|
const save = async (idpMapper: IdentityProviderMapperRepresentation) => {
|
||||||
const mapper = convertFormValuesToObject(
|
const mapper = convertFormValuesToObject(idpMapper);
|
||||||
idpMapper
|
|
||||||
) as IdentityProviderMapperRepresentation;
|
|
||||||
const attributes = JSON.stringify(idpMapper.config.attributes ?? []);
|
const attributes = JSON.stringify(idpMapper.config.attributes ?? []);
|
||||||
const claims = JSON.stringify(idpMapper.config.claims ?? []);
|
const claims = JSON.stringify(idpMapper.config.claims ?? []);
|
||||||
|
|
||||||
|
@ -171,6 +169,7 @@ export default function AddMapper() {
|
||||||
"config.attributes",
|
"config.attributes",
|
||||||
JSON.parse(mapper.config.attributes || "{}")
|
JSON.parse(mapper.config.attributes || "{}")
|
||||||
);
|
);
|
||||||
|
form.setValue("config.claims", JSON.parse(mapper.config.claims || "{}"));
|
||||||
};
|
};
|
||||||
|
|
||||||
if (!mapperTypes || !currentMapper) {
|
if (!mapperTypes || !currentMapper) {
|
||||||
|
|
Loading…
Reference in a new issue