fix for empty channels #636
This commit is contained in:
parent
72ad1552cb
commit
ab3aa0501c
1 changed files with 4 additions and 5 deletions
|
@ -384,16 +384,15 @@ export function doFetchClaimsByChannel(uri, page) {
|
|||
});
|
||||
|
||||
lbry.claim_list_by_channel({ uri, page: page || 1 }).then(result => {
|
||||
const claimResult = result[uri],
|
||||
claims = claimResult ? claimResult.claims_in_channel : [],
|
||||
currentPage = claimResult ? claimResult.returned_page : undefined;
|
||||
const claimResult = result[uri] || {};
|
||||
const { claims_in_channel, returned_page } = claimResult;
|
||||
|
||||
dispatch({
|
||||
type: types.FETCH_CHANNEL_CLAIMS_COMPLETED,
|
||||
data: {
|
||||
uri,
|
||||
claims,
|
||||
page: currentPage,
|
||||
claims: claims_in_channel || [],
|
||||
page: returned_page,
|
||||
},
|
||||
});
|
||||
});
|
||||
|
|
Loading…
Add table
Reference in a new issue