Type fixes

pull/9078/head
zomars 2022-11-25 06:03:40 -07:00
parent faa685adb6
commit 94ecb1908a
1 changed files with 1 additions and 2 deletions

View File

@ -36,8 +36,7 @@ const patchHandler = async (req: NextApiRequest, res: NextApiResponse) => {
const caller = viewerRouter.createCaller(ctx); const caller = viewerRouter.createCaller(ctx);
try { try {
const { teamId } = schemaQueryTeamId.parse(req.query); const { teamId } = schemaQueryTeamId.parse(req.query);
const success_url = req.url?.replace("/publish", ""); return await caller.teams.publish({ teamId });
return await caller.teams.publish({ teamId, success_url });
} catch (cause) { } catch (cause) {
if (cause instanceof TRPCError) { if (cause instanceof TRPCError) {
const statusCode = getHTTPStatusCodeFromError(cause); const statusCode = getHTTPStatusCodeFromError(cause);