ClaimListDiscover: fix broken excludeUris
logic
This commit is contained in:
parent
8823461ebd
commit
cc8812d751
1 changed files with 4 additions and 3 deletions
|
@ -526,7 +526,7 @@ function ClaimListDiscover(props: Props) {
|
||||||
// --- direct uris
|
// --- direct uris
|
||||||
finalUris = uris;
|
finalUris = uris;
|
||||||
injectPinUrls(finalUris, orderParam, pins);
|
injectPinUrls(finalUris, orderParam, pins);
|
||||||
filterExcludedUris(finalUris, excludeUris);
|
finalUris = filterExcludedUris(finalUris, excludeUris);
|
||||||
} else {
|
} else {
|
||||||
// --- searched uris
|
// --- searched uris
|
||||||
if (isUnfetchedClaimSearch && prevUris.current) {
|
if (isUnfetchedClaimSearch && prevUris.current) {
|
||||||
|
@ -534,7 +534,7 @@ function ClaimListDiscover(props: Props) {
|
||||||
} else {
|
} else {
|
||||||
finalUris = claimSearchResult;
|
finalUris = claimSearchResult;
|
||||||
injectPinUrls(finalUris, orderParam, pins);
|
injectPinUrls(finalUris, orderParam, pins);
|
||||||
filterExcludedUris(finalUris, excludeUris);
|
finalUris = filterExcludedUris(finalUris, excludeUris);
|
||||||
prevUris.current = finalUris;
|
prevUris.current = finalUris;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -632,8 +632,9 @@ function ClaimListDiscover(props: Props) {
|
||||||
|
|
||||||
function filterExcludedUris(uris, excludeUris) {
|
function filterExcludedUris(uris, excludeUris) {
|
||||||
if (uris && excludeUris && excludeUris.length) {
|
if (uris && excludeUris && excludeUris.length) {
|
||||||
uris = uris.filter((uri) => !excludeUris.includes(uri));
|
return uris.filter((uri) => !excludeUris.includes(uri));
|
||||||
}
|
}
|
||||||
|
return uris;
|
||||||
}
|
}
|
||||||
|
|
||||||
// **************************************************************************
|
// **************************************************************************
|
||||||
|
|
Loading…
Reference in a new issue