fix: webview - mystay - check if we have webviewToken * fix: webview - mystay - check if we have webviewToken * Cleanup Approved-by: Joakim Jäderberg
26 lines
677 B
TypeScript
26 lines
677 B
TypeScript
import { getSavedPaymentCardsSafely } from "@/lib/trpc/memoizedRequests"
|
|
|
|
import { isLoggedInUser } from "@/utils/isLoggedInUser"
|
|
|
|
import PaymentClient from "./PaymentClient"
|
|
|
|
import type { PaymentProps } from "@/types/components/hotelReservation/enterDetails/payment"
|
|
|
|
export default async function Payment({
|
|
otherPaymentOptions,
|
|
supportedCards,
|
|
}: PaymentProps) {
|
|
const savedCreditCards = await getSavedPaymentCardsSafely({
|
|
supportedCards,
|
|
})
|
|
const isUserLoggedIn = await isLoggedInUser()
|
|
|
|
return (
|
|
<PaymentClient
|
|
otherPaymentOptions={otherPaymentOptions}
|
|
savedCreditCards={savedCreditCards}
|
|
isUserLoggedIn={isUserLoggedIn}
|
|
/>
|
|
)
|
|
}
|