Skip to content

Commit

Permalink
prettier
Browse files Browse the repository at this point in the history
  • Loading branch information
thatguyinabeanie committed Nov 10, 2024
1 parent 40037c2 commit cc3f8d6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
4 changes: 2 additions & 2 deletions apps/nextjs/src/app/api/cookies/user-id/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {

export const runtime = "edge";

export async function POST (_req: NextRequest) {
export async function POST(_req: NextRequest) {
const { userId } = await auth();
if (!userId) {
return NextResponse.json(
Expand Down Expand Up @@ -52,7 +52,7 @@ export async function POST (_req: NextRequest) {
return await setUserIdCookie(setCookies, userId, response);
}

async function setUserIdCookie (
async function setUserIdCookie(
setCookies: (name: string, value: string) => Promise<void>,
userId: string,
response: NextResponse,
Expand Down
7 changes: 3 additions & 4 deletions apps/nextjs/src/app/api/discord/interactions/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import type {
import type { NextRequest } from "next/server";
import type Pokedex from "pokedex-promise-v2";
import { NextResponse } from "next/server";
import { auth } from "@clerk/nextjs/server";
import {
InteractionResponseType,
InteractionType,
Expand All @@ -21,7 +22,6 @@ import type { RandomPicType } from "~/lib/discord/commands";
import { env } from "~/env";
import { commands } from "~/lib/discord/commands";
import { verifyInteractionRequest } from "~/lib/discord/verify-incoming-request";
import { auth } from "@clerk/nextjs/server";

/**
* Use edge runtime which is faster, cheaper, and has no cold-boot.
Expand All @@ -33,7 +33,7 @@ export const runtime = "edge";

const ROOT_URL = env.VERCEL_URL ? `https://${env.VERCEL_URL}` : env.ROOT_URL;

function capitalizeFirstLetter (s: string) {
function capitalizeFirstLetter(s: string) {
return s.charAt(0).toUpperCase() + s.slice(1);
}

Expand All @@ -42,8 +42,7 @@ function capitalizeFirstLetter (s: string) {
*
* @see https://discord.com/developers/docs/interactions/receiving-and-responding#receiving-an-interaction
*/
export async function POST (request: NextRequest) {

export async function POST(request: NextRequest) {
const { userId } = await auth();
if (!userId) {
return NextResponse.json(
Expand Down

0 comments on commit cc3f8d6

Please sign in to comment.