Skip to content
This repository has been archived by the owner on Mar 12, 2023. It is now read-only.

Commit

Permalink
Merge pull request #20 from otoyo/fix-url-join
Browse files Browse the repository at this point in the history
Fix URL join
  • Loading branch information
otoyo authored Dec 19, 2021
2 parents aa3bfe6 + 63f5b12 commit 0f4a234
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/pages/blog/[slug].tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
const path = require('path')

import React, { useEffect } from 'react'
import Link from 'next/link'
import { useRouter } from 'next/router'
Expand Down Expand Up @@ -321,7 +319,7 @@ const RenderPost = ({
{NEXT_PUBLIC_URL && (
<SocialButtons
title={post.Title}
url={path.join(NEXT_PUBLIC_URL, getBlogLink(post.Slug))}
url={new URL(getBlogLink(post.Slug), NEXT_PUBLIC_URL)}
id={post.Slug}
/>
)}
Expand Down

1 comment on commit 0f4a234

@vercel
Copy link

@vercel vercel bot commented on 0f4a234 Dec 19, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.