Use default attributes in import form (#4052)

This commit is contained in:
Erik Jan de Wit 2023-01-03 10:49:25 -05:00 committed by GitHub
parent ec31aeee41
commit b5e9eb4620
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -87,7 +87,10 @@ export default function ImportForm() {
try {
const newClient = await adminClient.clients.create({
...imported,
...convertFormValuesToObject(client),
...convertFormValuesToObject({
...client,
attributes: client.attributes || {},
}),
});
addAlert(t("clientImportSuccess"), AlertVariant.success);
navigate(toClient({ realm, clientId: newClient.id, tab: "settings" }));