Revert "fix streamUrl creation"

This reverts commit 338f7be78e.
This commit is contained in:
Sean Yesmunt 2020-04-08 13:43:29 -04:00
parent 338f7be78e
commit 7401a590cc
2 changed files with 3 additions and 3 deletions

View file

@ -67,7 +67,7 @@ function buildClaimOgMetadata(uri, claim, overrideOptions = {}) {
let imageThumbnail;
if (Number(claim.fee) <= 0 && claim.source_media_type.startsWith('image/')) {
imageThumbnail = generateStreamUrl(claim.name, claim.claim_id, undefined, undefined, true);
imageThumbnail = generateStreamUrl(claimName, claim.claim_id);
}
const claimThumbnail = escapeHtmlProperty(claim.thumbnail_url) || imageThumbnail || `${URL}/v1-og.png`;

View file

@ -4,9 +4,9 @@ const { getCookie, setCookie } = require('../../ui/util/saved-passwords');
const CONTINENT_COOKIE = 'continent';
function generateStreamUrl(claimName, claimId, apiUrl, streamingContinent, useDefaultServer) {
function generateStreamUrl(claimName, claimId, apiUrl, streamingContinent) {
let prefix = LBRY_TV_STREAMING_API || apiUrl;
const continent = useDefaultServer ? undefined : streamingContinent || getCookie(CONTINENT_COOKIE);
const continent = streamingContinent || getCookie(CONTINENT_COOKIE);
if (continent && prefix.split('//').length > 1) {
prefix = prefix.replace('//', '//' + continent + '.');