diff --git a/src/app/news/[id]/page.tsx b/src/app/news/[id]/page.tsx index 0785d04..698e8c0 100644 --- a/src/app/news/[id]/page.tsx +++ b/src/app/news/[id]/page.tsx @@ -7,16 +7,10 @@ import message from "./icons/message.svg"; import calendar from "./icons/calendar.svg"; import ReviewSection from "@/widgets/ReviewSection/ReviewSection"; -const NewsDetails = async ({ - params, -}: { - params: { id: string }; -}) => { +const NewsDetails = async ({ params }: { params: { id: string } }) => { const getNewsById = async () => { - const response = await apiInstance.get( - `/news/${params.id}/` - ); - + const response = await apiInstance.get(`/news/${params.id}/`); + console.log(response); return response.data; }; @@ -48,9 +42,9 @@ const NewsDetails = async ({ Calendar Icon

{months[data.created_at.slice(5, 7)]}{" "} - {data.created_at.slice(5, 7).slice(0, 1) === "0" - ? data.created_at.slice(6, 7) - : data.created_at.slice(5, 7)} + {data.created_at.slice(8, 10) === "0" + ? data.created_at.slice(9, 10) + : data.created_at.slice(8, 10)} , {data.created_at.slice(0, 4)}