Fix User Event Types not visible when 'Save events disabled` (#20581)
Fixes #20503
This commit is contained in:
parent
1b06c4cf6c
commit
88bb5977cd
1 changed files with 14 additions and 16 deletions
|
@ -195,14 +195,13 @@ export const EventsTab = ({ realm }: EventsTabProps) => {
|
|||
/>
|
||||
</FormAccess>
|
||||
</PageSection>
|
||||
{events?.eventsEnabled && (
|
||||
<PageSection>
|
||||
<EventsTypeTable
|
||||
key={tableKey}
|
||||
addTypes={() => setAddEventType(true)}
|
||||
eventTypes={events.enabledEventTypes || []}
|
||||
eventTypes={events?.enabledEventTypes || []}
|
||||
onDelete={(value) => {
|
||||
const enabledEventTypes = events.enabledEventTypes?.filter(
|
||||
const enabledEventTypes = events?.enabledEventTypes?.filter(
|
||||
(e) => e !== value.id
|
||||
);
|
||||
addEvents(enabledEventTypes);
|
||||
|
@ -210,7 +209,6 @@ export const EventsTab = ({ realm }: EventsTabProps) => {
|
|||
}}
|
||||
/>
|
||||
</PageSection>
|
||||
)}
|
||||
</Tab>
|
||||
<Tab
|
||||
eventKey="admin"
|
||||
|
|
Loading…
Reference in a new issue