diff --git a/ui/component/claimListDiscover/view.jsx b/ui/component/claimListDiscover/view.jsx index 2e83eaf6a..906d96980 100644 --- a/ui/component/claimListDiscover/view.jsx +++ b/ui/component/claimListDiscover/view.jsx @@ -204,10 +204,11 @@ function ClaimListDiscover(props: Props) { } if (!showReposts) { - options.claim_type = - options.claim_type === undefined - ? ['stream', 'channel'] - : options.claim_type.filter(claimType => claimType !== 'repost'); + if (Array.isArray(options.claim_type)) { + options.claim_type = options.claim_type.filter(claimType => claimType !== 'repost'); + } else { + options.claim_type = ['stream', 'channel']; + } } const hasMatureTags = tags && tags.some(t => MATURE_TAGS.includes(t)); diff --git a/ui/component/claimTilesDiscover/view.jsx b/ui/component/claimTilesDiscover/view.jsx index 98fff9214..b9c79e845 100644 --- a/ui/component/claimTilesDiscover/view.jsx +++ b/ui/component/claimTilesDiscover/view.jsx @@ -77,10 +77,11 @@ function ClaimTilesDiscover(props: Props) { } if (!showReposts) { - options.claim_type = - options.claim_type === undefined - ? ['stream', 'channel'] - : options.claim_type.filter(claimType => claimType !== 'repost'); + if (Array.isArray(options.claim_type)) { + options.claim_type = options.claim_type.filter(claimType => claimType !== 'repost'); + } else { + options.claim_type = ['stream', 'channel']; + } } if (claimType) {