chore: Extend eslint configs from @typescript-eslint/recommended * Change to typescript recommended in scandic-web * Remove comment * Change to recommended ts config in partner-sas * Change to recommended ts lint config in booking-flow Approved-by: Linus Flood
32 lines
1.0 KiB
TypeScript
32 lines
1.0 KiB
TypeScript
import { PaymentCallbackPage as PaymentCallbackPagePrimitive } from "@scandic-hotels/booking-flow/pages/PaymentCallbackPage"
|
|
import { logger } from "@scandic-hotels/common/logger"
|
|
|
|
import type { PaymentCallbackStatusEnum } from "@scandic-hotels/common/constants/paymentCallbackStatusEnum"
|
|
|
|
import type { LangParams, PageArgs } from "@/types/params"
|
|
|
|
export default async function PaymentCallbackPage(
|
|
props: PageArgs<LangParams & { status: string }>
|
|
) {
|
|
const searchParams = await props.searchParams
|
|
const params = await props.params
|
|
logger.debug(`[payment-callback] callback started`)
|
|
const lang = params.lang
|
|
|
|
const userAccessToken = null
|
|
// TODO fix when auth is implemented
|
|
// const session = await auth()
|
|
// if (isValidSession(session)) {
|
|
// userAccessToken = session.token.access_token
|
|
// }
|
|
|
|
return (
|
|
<PaymentCallbackPagePrimitive
|
|
lang={lang}
|
|
userAccessToken={userAccessToken}
|
|
searchParams={searchParams}
|
|
status={params.status as PaymentCallbackStatusEnum}
|
|
/>
|
|
)
|
|
}
|