We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4be12a6 commit 7b689daCopy full SHA for 7b689da
web/app/chat/[id]/page.tsx
@@ -1,5 +1,6 @@
1
"use client";
2
import type { DMRoom, PersonalizedDMRoom } from "common/types";
3
+import Link from "next/link";
4
import { useEffect, useState } from "react";
5
import * as chat from "~/api/chat/chat";
6
import { RoomWindow } from "~/components/chat/RoomWindow";
@@ -16,8 +17,16 @@ export default function Page({ params }: { params: { id: string } }) {
16
17
18
return (
19
<>
- <p>idは{id}です。</p>
20
- {room ? <RoomWindow friendId={id} room={room} /> : <p>データないよ</p>}
+ {room ? (
21
+ <RoomWindow friendId={id} room={room} />
22
+ ) : (
23
+ <p>
24
+ Sorry, an unexpected error has occurred.
25
+ <Link href="/home" className="text-blue-600">
26
+ Go Back
27
+ </Link>
28
+ </p>
29
+ )}
30
</>
31
);
32
}
0 commit comments