diff --git a/frontend/src/app/blog/[articleSlug]/page.tsx b/frontend/src/app/blog/[articleSlug]/page.tsx index 5b9fe37..a9efcdf 100644 --- a/frontend/src/app/blog/[articleSlug]/page.tsx +++ b/frontend/src/app/blog/[articleSlug]/page.tsx @@ -4,8 +4,8 @@ import { BlocksContent } from "@strapi/blocks-react-renderer"; import BlockRendererClient from "@/components/BlockRendererClient"; import { gql } from "@/__generated__/gql"; import { getClient } from "@/lib/ApolloClient"; -import { AvatarImageFix } from "@/components/AvatarImageFix"; import ShareButtons from "@/components/ShareButtons"; +import NextImage from "next/image"; const STRAPI_URL = process.env.STRAPI_URL; @@ -92,14 +92,18 @@ export default async function Page({
{avatarURL && ( - - - {// Get initials from author name - authorName - ?.split(" ") - .map((name: any) => name[0]) - .join("")} - + {avatarURL && ( + + )} + {!avatarURL && ( + + {// Get initials from author name + authorName + ?.split(" ") + .map((name: any) => name[0]) + .join("")} + + )} )}