Skip to content

Commit

Permalink
fix(): only provide one HeadContent
Browse files Browse the repository at this point in the history
  • Loading branch information
moritzrinow committed Nov 25, 2024
1 parent 5953b48 commit 038bee1
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/CoreBlog.Server/src/Components/Pages/Post.razor
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@ else
<meta name="og:title" content="@PostMetadata.Title"/>
<meta name="og:description" content="@PostMetadata.Summary"/>
<meta name="description" content="@PostMetadata.Summary"/>
@if (PostMetadata.Thumbnail is { } thumbnail && storage.GetAssetUrl(thumbnail) is { } thumbnailUrl)
{
<meta name="og:image" content="@thumbnailUrl"/>
}
</HeadContent>

<article lang="@PostMetadata.Language">
Expand All @@ -40,10 +44,6 @@ else
}
@if (PostMetadata.Thumbnail is { } thumbnail && storage.GetAssetUrl(thumbnail) is { } thumbnailUrl)
{
<HeadContent>
<meta name="og:image" content="@thumbnailUrl"/>
</HeadContent>

<RadzenImage
Path="@thumbnailUrl"/>
}
Expand Down

0 comments on commit 038bee1

Please sign in to comment.