fix(SW-360): better handleSubmit error handling
This commit is contained in:
committed by
Pontus Dreij
parent
540ce58446
commit
3407d48f6a
@@ -140,20 +140,6 @@ export const serverActionProcedure = t.procedure.experimental_caller(
|
||||
})
|
||||
)
|
||||
|
||||
export const hotelServiceServerActionProcedure = serverActionProcedure.use(
|
||||
async (opts) => {
|
||||
const { access_token } = await fetchServiceToken(["hotel"])
|
||||
if (!access_token) {
|
||||
throw internalServerError("Failed to obtain service token")
|
||||
}
|
||||
return opts.next({
|
||||
ctx: {
|
||||
serviceToken: access_token,
|
||||
},
|
||||
})
|
||||
}
|
||||
)
|
||||
|
||||
export const profileServiceServerActionProcedure = serverActionProcedure.use(
|
||||
async (opts) => {
|
||||
const { access_token } = await fetchServiceToken(["profile"])
|
||||
|
||||
Reference in New Issue
Block a user