Allowing parent affiliate URL if channel uses the same URL as network.
This commit is contained in:
@@ -71,7 +71,7 @@ export function getAffiliateEntityUrl(entity) {
|
||||
? entity.affiliate.parameters.replaceEntity.url
|
||||
: entity.affiliate.url;
|
||||
|
||||
if (entity.id === entity.affiliate.entityId) {
|
||||
if (entity.id === entity.affiliate.entityId || entity.url === entity.parent?.url) {
|
||||
return affiliateUrl;
|
||||
}
|
||||
|
||||
@@ -80,7 +80,7 @@ export function getAffiliateEntityUrl(entity) {
|
||||
}
|
||||
|
||||
// channel has its own domain
|
||||
if (new URL(entity.url).pathname === '/') {
|
||||
if (new URL(entity.url).pathname === '/' && entity.url !== entity.parent?.url) {
|
||||
return entity.url;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user