fix: copy link from route object

resolves #289
This commit is contained in:
Daniel Roe 2022-12-02 09:59:09 +00:00
parent 9e9f2bde09
commit 8fc6148a3b
No known key found for this signature in database
GPG key ID: 22D5008E4F5D9B55

View file

@ -37,7 +37,7 @@ const toggleTranslation = async () => {
}
const copyLink = async (status: Status) => {
const url = getStatusPermalinkRoute(status)
const url = getStatusPermalinkRoute(status)?.href
if (url)
await clipboard.copy(`${location.origin}${url}`)
}