0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2025-02-17 22:04:19 -05:00

fix(console): fix SAML app creation API usage (#6990)

This commit is contained in:
Darcy Ye 2025-01-28 07:24:46 +08:00 committed by GitHub
parent a213856ea2
commit 8f387cd86b
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -10,7 +10,6 @@ import Modal from 'react-modal';
import { useSWRConfig } from 'swr';
import { GtagConversionId, reportConversion } from '@/components/Conversion/utils';
import { isDevFeaturesEnabled } from '@/consts/env';
import { latestProPlanId } from '@/consts/subscriptions';
import { SubscriptionDataContext } from '@/contexts/SubscriptionDataProvider';
import DynamicT from '@/ds-components/DynamicT';
@ -94,10 +93,7 @@ function CreateForm({
}
const appCreationEndpoint =
// TODO: @darcy remove this after the SAML is implemented
isDevFeaturesEnabled && data.type === ApplicationType.SAML
? 'api/saml-applications'
: 'api/applications';
data.type === ApplicationType.SAML ? 'api/saml-applications' : 'api/applications';
const createdApp = await api.post(appCreationEndpoint, { json: data }).json<Application>();