Filter preview #2621

Merged
jessopb merged 3 commits from filterPreview into master 2019-07-17 05:32:30 +02:00
jessopb commented 2019-07-10 16:11:17 +02:00 (Migrated from github.com)

Filters out discovery previews based on file list_filtered api.

Filters out discovery previews based on file list_filtered api.
kauffj (Migrated from github.com) reviewed 2019-07-10 17:13:41 +02:00
@ -71,0 +71,4 @@
}
if (claim && !shouldHide && filteredOutpoints) {
shouldHide = filteredOutpoints.some(outpoint => outpoint.txid === claim.txid && outpoint.nout === claim.nout);
kauffj (Migrated from github.com) commented 2019-07-10 17:13:40 +02:00
filteredOutpoints.reduce((outpoint, carry) => return carry || outpoint.txid === claim.txid && outpoint.nout === claim.nout);
``` filteredOutpoints.reduce((outpoint, carry) => return carry || outpoint.txid === claim.txid && outpoint.nout === claim.nout); ```
neb-b (Migrated from github.com) approved these changes 2019-07-10 18:24:20 +02:00
neb-b (Migrated from github.com) left a comment

Can merge once the lbryinc PR is good to go

Can merge once the lbryinc PR is good to go
jessopb (Migrated from github.com) reviewed 2019-07-11 03:18:41 +02:00
@ -71,0 +71,4 @@
}
if (claim && !shouldHide && filteredOutpoints) {
shouldHide = filteredOutpoints.some(outpoint => outpoint.txid === claim.txid && outpoint.nout === claim.nout);
jessopb (Migrated from github.com) commented 2019-07-11 03:18:40 +02:00

// failfast array.prototype.some()

shouldHide = filteredOutpoints.some( 
  outpoint => 
  outpoint.txid === claim.txid && 
  outpoint.nout === claim.nout 
)
// failfast array.prototype.some() ``` shouldHide = filteredOutpoints.some( outpoint => outpoint.txid === claim.txid && outpoint.nout === claim.nout ) ```
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: LBRYCommunity/lbry-desktop#2621
No description provided.