Update
This commit is contained in:
@@ -1,16 +1,13 @@
|
||||
import { auth } from "@/auth";
|
||||
import Banner from "@/components/Banner";
|
||||
import ProjectsTable, { Project } from "@/components/ProjectsTable";
|
||||
import { prisma } from "@/lib/prisma";
|
||||
import { notFound, redirect } from "next/navigation";
|
||||
import { notFound } from "next/navigation";
|
||||
|
||||
type Props = {
|
||||
params: { username: string };
|
||||
};
|
||||
|
||||
export default async function UserProfilePage({ params }: Props) {
|
||||
const session = await auth();
|
||||
if (!session) return redirect("/");
|
||||
|
||||
const username = params.username;
|
||||
const user = await prisma.user.findUnique({
|
||||
|
||||
@@ -167,7 +167,7 @@ export default function ProjectTable({
|
||||
<span className="font-mono tabular-nums">{p.coords}</span>
|
||||
{p.coords && (
|
||||
<a
|
||||
href={`https://maps.aystone.fr/cobble/#world:${p.coords.replace(/ /g, ":")}:1500:0:0:0:0:perspective`}
|
||||
href={`https://maps.aystone.fr/cobble/#world:${p.coords.replace(/ /g, ":")}:1500:0:0:0:0:free`}
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
className="inline-block rounded bg-blue-600 px-2 py-0.5 text-[11px] text-white hover:bg-blue-700"
|
||||
|
||||
Reference in New Issue
Block a user