OG: Skip 'data:image' when generating cards.odysee.com urls
## Issue 513 Meta: Invalid "card.odysee.com" used as thumbnailUrl
This commit is contained in:
parent
e2b8573269
commit
72c1a8ae25
1 changed files with 1 additions and 1 deletions
|
@ -50,7 +50,7 @@ function getThumbnailCdnUrl(url) {
|
||||||
return url;
|
return url;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (url) {
|
if (url && !url.startsWith('data:image')) {
|
||||||
const encodedURL = Buffer.from(url).toString('base64');
|
const encodedURL = Buffer.from(url).toString('base64');
|
||||||
return `${THUMBNAIL_CARDS_CDN_URL}${encodedURL}.jpg`;
|
return `${THUMBNAIL_CARDS_CDN_URL}${encodedURL}.jpg`;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue