Format changes with prettier
This commit is contained in:
parent
7828753d49
commit
d8cd9497cc
3 changed files with 28 additions and 23 deletions
|
@ -32,8 +32,7 @@ const perform = dispatch => ({
|
|||
navigate: (path, params) => dispatch(doNavigate(path, params)),
|
||||
fetchFileInfo: uri => dispatch(doFetchFileInfo(uri)),
|
||||
fetchCostInfo: uri => dispatch(doFetchCostInfoForUri(uri)),
|
||||
checkSubscription: (subscription) =>
|
||||
dispatch(doCheckSubscription(subscription)),
|
||||
checkSubscription: subscription => dispatch(doCheckSubscription(subscription)),
|
||||
});
|
||||
|
||||
export default connect(select, perform)(FilePage);
|
||||
|
|
|
@ -42,17 +42,16 @@ class FilePage extends React.PureComponent {
|
|||
.map(subscription => subscription.channelName)
|
||||
.indexOf(props.claim.channel_name) !== -1
|
||||
) {
|
||||
props.checkSubscription(
|
||||
{
|
||||
channelName: props.claim.channel_name,
|
||||
uri: buildURI(
|
||||
{
|
||||
contentName: props.claim.channel_name,
|
||||
claimId: props.claim.value.publisherSignature.certificateId,
|
||||
},
|
||||
false
|
||||
),
|
||||
});
|
||||
props.checkSubscription({
|
||||
channelName: props.claim.channel_name,
|
||||
uri: buildURI(
|
||||
{
|
||||
contentName: props.claim.channel_name,
|
||||
claimId: props.claim.value.publisherSignature.certificateId,
|
||||
},
|
||||
false
|
||||
),
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -38,7 +38,9 @@ export const doCheckSubscriptions = () => (
|
|||
});
|
||||
};
|
||||
|
||||
export const doCheckSubscription = (subscription: Subscription, notify?: boolean) => (dispatch: Dispatch) => {
|
||||
export const doCheckSubscription = (subscription: Subscription, notify?: boolean) => (
|
||||
dispatch: Dispatch
|
||||
) => {
|
||||
dispatch({
|
||||
type: ACTIONS.CHECK_SUBSCRIPTION_STARTED,
|
||||
data: subscription,
|
||||
|
@ -90,16 +92,21 @@ export const doCheckSubscription = (subscription: Subscription, notify?: boolean
|
|||
};
|
||||
}
|
||||
|
||||
dispatch(setSubscriptionLatest({
|
||||
channelName: claimsInChannel[0].channel_name,
|
||||
uri: buildURI(
|
||||
{ channelName: claimsInChannel[0].channel_name, claimId: claimsInChannel[0].claim_id },
|
||||
false
|
||||
dispatch(
|
||||
setSubscriptionLatest(
|
||||
{
|
||||
channelName: claimsInChannel[0].channel_name,
|
||||
uri: buildURI(
|
||||
{ channelName: claimsInChannel[0].channel_name, claimId: claimsInChannel[0].claim_id },
|
||||
false
|
||||
),
|
||||
},
|
||||
buildURI(
|
||||
{ contentName: claimsInChannel[0].name, claimId: claimsInChannel[0].claim_id },
|
||||
false
|
||||
)
|
||||
)
|
||||
}, buildURI(
|
||||
{ contentName: claimsInChannel[0].name, claimId: claimsInChannel[0].claim_id },
|
||||
false
|
||||
)));
|
||||
);
|
||||
|
||||
dispatch({
|
||||
type: ACTIONS.CHECK_SUBSCRIPTION_COMPLETED,
|
||||
|
|
Loading…
Reference in a new issue