Fix variable name confusion

Per convention, 'ByUri' would mean it's the array/object that is storing the entire list, but this is actually the specific entry.
This commit is contained in:
infinite-persistence 2022-05-25 14:30:23 +08:00
parent 58270ab758
commit 4aa94a7bfd
No known key found for this signature in database
GPG key ID: B9C3252EDC3D0AA0
2 changed files with 4 additions and 4 deletions

View file

@ -8,7 +8,7 @@ const select = (state, props) => {
return { return {
claim: selectClaimForUri(state, uri), claim: selectClaimForUri(state, uri),
isResolvingUri: selectIsUriResolving(state, uri), isResolvingUri: selectIsUriResolving(state, uri),
odyseeMembershipByUri: selectOdyseeMembershipForUri(state, uri), odyseeMembership: selectOdyseeMembershipForUri(state, uri),
}; };
}; };

View file

@ -12,11 +12,11 @@ type Props = {
claim: ?Claim, claim: ?Claim,
uri: string, uri: string,
isResolvingUri: boolean, isResolvingUri: boolean,
odyseeMembershipByUri: ?string, odyseeMembership: ?string,
}; };
export default function WunderbarSuggestion(props: Props) { export default function WunderbarSuggestion(props: Props) {
const { claim, uri, isResolvingUri, odyseeMembershipByUri } = props; const { claim, uri, isResolvingUri, odyseeMembership } = props;
if (isResolvingUri) { if (isResolvingUri) {
return ( return (
@ -63,7 +63,7 @@ export default function WunderbarSuggestion(props: Props) {
<div className="wunderbar__suggestion-title">{claim.value.title}</div> <div className="wunderbar__suggestion-title">{claim.value.title}</div>
<div className="wunderbar__suggestion-name"> <div className="wunderbar__suggestion-name">
{isChannel ? claim.name : (claim.signing_channel && claim.signing_channel.name) || __('Anonymous')} {isChannel ? claim.name : (claim.signing_channel && claim.signing_channel.name) || __('Anonymous')}
<PremiumBadge membership={odyseeMembershipByUri} /> <PremiumBadge membership={odyseeMembership} />
</div> </div>
</span> </span>
</div> </div>