diff --git a/pages/minecraft/players/[uuid].js b/pages/minecraft/players/[uuid].js
index 281b554..c0ad62a 100644
--- a/pages/minecraft/players/[uuid].js
+++ b/pages/minecraft/players/[uuid].js
@@ -1,4 +1,4 @@
-// Base layout
+ // Base layout
import Layout from "../../components/Layout"
// React
@@ -15,10 +15,9 @@ export default function UUID() {
const router = useRouter()
const { uuid } = router.query
const { data, error } = useSwr(
- router.query.id ? `/api/user/${router.query.id}` : null,
+ uuid ? `/api/PlayerName/${uuid}` : null,
fetcher
)
-
if (error) {
return (
<>
@@ -27,23 +26,23 @@ export default function UUID() {
>
)
+ } else {
+ if (!data) {
+ return (
+ <>
+
+
+
+ >
+ )
+ } else {
+ return (
+ <>
+
+
+
+ >
+ )
+ }
}
-
- if (!data) {
- return (
- <>
-
-
-
- >
- )
- }
-
- return (
- <>
- + " - " + "プレイヤー情報"}>
-
-
- >
- )
}