feat: improve handling of stays

This commit is contained in:
Matilda Landström
2024-07-16 17:21:58 +02:00
committed by Michael Zetterberg
parent e733ce283a
commit f46207a308
11 changed files with 39 additions and 46 deletions

View File

@@ -28,7 +28,6 @@ export const friendTransactionsInput = z
})
.default({ limit: 5, page: 1 })
// Mutation
export const addCreditCardInput = z.object({
language: z.string(),

View File

@@ -379,16 +379,6 @@ export const userQueryRouter = router({
)
if (!apiResponse.ok) {
// switch (apiResponse.status) {
// case 400:
// throw badRequestError(apiResponse)
// case 401:
// throw unauthorizedError(apiResponse)
// case 403:
// throw forbiddenError(apiResponse)
// default:
// throw internalServerError(apiResponse)
// }
const text = await apiResponse.text()
console.error(
"api.booking.stays.past error ",
@@ -464,16 +454,6 @@ export const userQueryRouter = router({
)
if (!apiResponse.ok) {
// switch (apiResponse.status) {
// case 400:
// throw badRequestError(apiResponse)
// case 401:
// throw unauthorizedError(apiResponse)
// case 403:
// throw forbiddenError(apiResponse)
// default:
// throw internalServerError(apiResponse)
// }
const text = await apiResponse.text()
console.error(
"api.booking.stays.future error ",